Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
7391bc56
Commit
7391bc56
authored
Feb 07, 2003
by
monty@mashka.mysql.fi
Browse files
Options
Browse Files
Download
Plain Diff
Merge work:/my/mysql-4.0 into mashka.mysql.fi:/home/my/mysql-4.0
parents
a1a63f2d
1b9b0426
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
45 additions
and
9 deletions
+45
-9
mysql-test/r/explain.result
mysql-test/r/explain.result
+13
-0
mysql-test/r/func_crypt.result
mysql-test/r/func_crypt.result
+6
-3
mysql-test/t/explain.test
mysql-test/t/explain.test
+8
-0
mysql-test/t/func_crypt.test
mysql-test/t/func_crypt.test
+2
-1
sql/item_create.cc
sql/item_create.cc
+5
-0
sql/item_create.h
sql/item_create.h
+1
-0
sql/lex.h
sql/lex.h
+1
-1
sql/opt_range.cc
sql/opt_range.cc
+0
-2
sql/opt_sum.cc
sql/opt_sum.cc
+9
-2
No files found.
mysql-test/r/explain.result
View file @
7391bc56
...
...
@@ -31,3 +31,16 @@ drop table t1;
explain select 1;
Comment
No tables used
create table t1 (a int not null);
explain select count(*) from t1;
Comment
Select tables optimized away
insert into t1 values(1);
explain select count(*) from t1;
Comment
Select tables optimized away
insert into t1 values(1);
explain select count(*) from t1;
Comment
Select tables optimized away
drop table t1;
mysql-test/r/func_crypt.result
View file @
7391bc56
select length(encrypt('foo', 'ff')) <> 0;
length(encrypt('foo', 'ff')) <> 0
1
select password('test'),length(encrypt('test')),encrypt('test','aa');
password('test') length(encrypt('test')) encrypt('test','aa')
378b243e220ca493 13 aaqPiZY5xR5l.
select old_password('test'), password('test');
old_password('test') password('test')
378b243e220ca493 378b243e220ca493
select length(encrypt('test')), encrypt('test','aa');
length(encrypt('test')) encrypt('test','aa')
13 aaqPiZY5xR5l.
mysql-test/t/explain.test
View file @
7391bc56
...
...
@@ -20,3 +20,11 @@ explain select * from t1 ignore key (str,str,foo) where str="foo";
drop
table
t1
;
explain
select
1
;
create
table
t1
(
a
int
not
null
);
explain
select
count
(
*
)
from
t1
;
insert
into
t1
values
(
1
);
explain
select
count
(
*
)
from
t1
;
insert
into
t1
values
(
1
);
explain
select
count
(
*
)
from
t1
;
drop
table
t1
;
mysql-test/t/func_crypt.test
View file @
7391bc56
...
...
@@ -2,4 +2,5 @@
select
length
(
encrypt
(
'foo'
,
'ff'
))
<>
0
;
--
replace_result
$
1
$aa
$
4
OSUA5cjdx0RUQ08opV27
/
aaqPiZY5xR5l
.
select
password
(
'test'
),
length
(
encrypt
(
'test'
)),
encrypt
(
'test'
,
'aa'
);
select
old_password
(
'test'
),
password
(
'test'
);
select
length
(
encrypt
(
'test'
)),
encrypt
(
'test'
,
'aa'
);
sql/item_create.cc
View file @
7391bc56
...
...
@@ -307,6 +307,11 @@ Item *create_func_quarter(Item* a)
return
new
Item_func_quarter
(
a
);
}
Item
*
create_func_password
(
Item
*
a
)
{
return
new
Item_func_password
(
a
);
}
Item
*
create_func_radians
(
Item
*
a
)
{
return
new
Item_func_units
((
char
*
)
"radians"
,
a
,
M_PI
/
180
,
0.0
);
...
...
sql/item_create.h
View file @
7391bc56
...
...
@@ -70,6 +70,7 @@ Item *create_func_pi(void);
Item
*
create_func_pow
(
Item
*
a
,
Item
*
b
);
Item
*
create_func_current_user
(
void
);
Item
*
create_func_quarter
(
Item
*
a
);
Item
*
create_func_password
(
Item
*
a
);
Item
*
create_func_radians
(
Item
*
a
);
Item
*
create_func_release_lock
(
Item
*
a
);
Item
*
create_func_repeat
(
Item
*
a
,
Item
*
b
);
...
...
sql/lex.h
View file @
7391bc56
...
...
@@ -260,7 +260,6 @@ static SYMBOL symbols[] = {
{
"NULL"
,
SYM
(
NULL_SYM
),
0
,
0
},
{
"NUMERIC"
,
SYM
(
NUMERIC_SYM
),
0
,
0
},
{
"OFFSET"
,
SYM
(
OFFSET_SYM
),
0
,
0
},
{
"OLD_PASSWORD"
,
SYM
(
PASSWORD
),
0
,
0
},
{
"ON"
,
SYM
(
ON
),
0
,
0
},
{
"OPEN"
,
SYM
(
OPEN_SYM
),
0
,
0
},
{
"OPTIMIZE"
,
SYM
(
OPTIMIZE
),
0
,
0
},
...
...
@@ -475,6 +474,7 @@ static SYMBOL sql_functions[] = {
{
"NULLIF"
,
SYM
(
FUNC_ARG2
),
0
,
CREATE_FUNC
(
create_func_nullif
)},
{
"OCTET_LENGTH"
,
SYM
(
FUNC_ARG1
),
0
,
CREATE_FUNC
(
create_func_length
)},
{
"OCT"
,
SYM
(
FUNC_ARG1
),
0
,
CREATE_FUNC
(
create_func_oct
)},
{
"OLD_PASSWORD"
,
SYM
(
FUNC_ARG1
),
0
,
CREATE_FUNC
(
create_func_password
)},
{
"ORD"
,
SYM
(
FUNC_ARG1
),
0
,
CREATE_FUNC
(
create_func_ord
)},
{
"PERIOD_ADD"
,
SYM
(
FUNC_ARG2
),
0
,
CREATE_FUNC
(
create_func_period_add
)},
{
"PERIOD_DIFF"
,
SYM
(
FUNC_ARG2
),
0
,
CREATE_FUNC
(
create_func_period_diff
)},
...
...
sql/opt_range.cc
View file @
7391bc56
...
...
@@ -23,8 +23,6 @@
*/
#ifdef __GNUC__
#pragma implementation // gcc: Class implementation
#endif
...
...
sql/opt_sum.cc
View file @
7391bc56
...
...
@@ -245,8 +245,15 @@ int opt_sum_query(TABLE_LIST *tables, List<Item> &all_fields,COND *conds)
const_result
=
0
;
}
}
if
(
used_tables
!=
removed_tables
)
const_result
=
0
;
// We didn't remove all tables
/*
If we have a where clause, we can only ignore searching in the
tables if MIN/MAX optimisation replaced all used tables
This is to not to use replaced values in case of:
SELECT MIN(key) FROM table_1, empty_table
removed_tables is != 0 if we have used MIN() or MAX().
*/
if
(
removed_tables
&&
used_tables
!=
removed_tables
)
const_result
=
0
;
// We didn't remove all tables
return
const_result
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment