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
709a12ec
Commit
709a12ec
authored
Jan 13, 2004
by
serg@serg.mylan
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal:/home/bk/mysql-4.0/
into serg.mylan:/usr/home/serg/Abk/mysql-4.0
parents
bee338fe
90c6ecca
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
9 deletions
+47
-9
mysql-test/r/handler.result
mysql-test/r/handler.result
+18
-0
mysql-test/t/handler.test
mysql-test/t/handler.test
+16
-0
sql/sql_handler.cc
sql/sql_handler.cc
+3
-4
sql/sql_yacc.yy
sql/sql_yacc.yy
+10
-5
No files found.
mysql-test/r/handler.result
View file @
709a12ec
...
@@ -173,3 +173,21 @@ Unknown column 'W' in 'field list'
...
@@ -173,3 +173,21 @@ Unknown column 'W' in 'field list'
handler t1 read a=(a);
handler t1 read a=(a);
Wrong arguments to HANDLER ... READ
Wrong arguments to HANDLER ... READ
drop table t1;
drop table t1;
create table t1 (a char(5));
insert into t1 values ("Ok");
handler t1 open as t;
handler t read first;
a
Ok
use mysql;
handler t read first;
a
Ok
handler t close;
handler test.t1 open as t;
handler t read first;
a
Ok
handler t close;
use test;
drop table t1;
mysql-test/t/handler.test
View file @
709a12ec
...
@@ -107,3 +107,19 @@ handler t1 read a=(W);
...
@@ -107,3 +107,19 @@ handler t1 read a=(W);
handler
t1
read
a
=
(
a
);
handler
t1
read
a
=
(
a
);
drop
table
t1
;
drop
table
t1
;
#
# BUG#2304
#
create
table
t1
(
a
char
(
5
));
insert
into
t1
values
(
"Ok"
);
handler
t1
open
as
t
;
handler
t
read
first
;
use
mysql
;
handler
t
read
first
;
handler
t
close
;
handler
test
.
t1
open
as
t
;
handler
t
read
first
;
handler
t
close
;
use
test
;
drop
table
t1
;
sql/sql_handler.cc
View file @
709a12ec
...
@@ -276,14 +276,13 @@ static TABLE **find_table_ptr_by_name(THD *thd, const char *db,
...
@@ -276,14 +276,13 @@ static TABLE **find_table_ptr_by_name(THD *thd, const char *db,
int
dblen
;
int
dblen
;
TABLE
**
ptr
;
TABLE
**
ptr
;
if
(
!
db
||
!
*
db
)
DBUG_ASSERT
(
db
);
db
=
thd
->
db
?
thd
->
db
:
""
;
dblen
=*
db
?
strlen
(
db
)
+
1
:
0
;
dblen
=
strlen
(
db
)
+
1
;
ptr
=&
(
thd
->
handler_tables
);
ptr
=&
(
thd
->
handler_tables
);
for
(
TABLE
*
table
=*
ptr
;
table
;
table
=*
ptr
)
for
(
TABLE
*
table
=*
ptr
;
table
;
table
=*
ptr
)
{
{
if
(
!
memcmp
(
table
->
table_cache_key
,
db
,
dblen
)
&&
if
(
(
!
dblen
||
!
memcmp
(
table
->
table_cache_key
,
db
,
dblen
)
)
&&
!
my_strcasecmp
((
is_alias
?
table
->
table_name
:
table
->
real_name
),
table_name
))
!
my_strcasecmp
((
is_alias
?
table
->
table_name
:
table
->
real_name
),
table_name
))
{
{
if
(
table
->
version
!=
refresh_version
)
if
(
table
->
version
!=
refresh_version
)
...
...
sql/sql_yacc.yy
View file @
709a12ec
...
@@ -501,7 +501,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b,int *yystacksize);
...
@@ -501,7 +501,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b,int *yystacksize);
opt_table_alias
opt_table_alias
%type <table>
%type <table>
table_ident
table_ident
table_ident_ref
%type <simple_string>
%type <simple_string>
remember_name remember_end opt_len opt_ident opt_db text_or_password
remember_name remember_end opt_len opt_ident opt_db text_or_password
...
@@ -3243,8 +3243,13 @@ field_ident:
...
@@ -3243,8 +3243,13 @@ field_ident:
table_ident:
table_ident:
ident { $$=new Table_ident($1); }
ident { $$=new Table_ident($1); }
| ident '.' ident { $$=new Table_ident($1,$3,0);}
| ident '.' ident { $$=new Table_ident($1,$3,0);}
| '.' ident { $$=new Table_ident($2);}
| '.' ident { $$=new Table_ident($2);} /* For Delphi */
/* For Delphi */;
;
table_ident_ref:
ident { LEX_STRING db={"",0}; $$=new Table_ident(db,$1,0); }
| ident '.' ident { $$=new Table_ident($1,$3,0);}
;
ident:
ident:
IDENT { $$=$1; }
IDENT { $$=$1; }
...
@@ -3610,13 +3615,13 @@ handler:
...
@@ -3610,13 +3615,13 @@ handler:
if (!add_table_to_list($2,$4,0))
if (!add_table_to_list($2,$4,0))
YYABORT;
YYABORT;
}
}
| HANDLER_SYM table_ident CLOSE_SYM
| HANDLER_SYM table_ident
_ref
CLOSE_SYM
{
{
Lex->sql_command = SQLCOM_HA_CLOSE;
Lex->sql_command = SQLCOM_HA_CLOSE;
if (!add_table_to_list($2,0,0))
if (!add_table_to_list($2,0,0))
YYABORT;
YYABORT;
}
}
| HANDLER_SYM table_ident READ_SYM
| HANDLER_SYM table_ident
_ref
READ_SYM
{
{
LEX *lex=Lex;
LEX *lex=Lex;
lex->sql_command = SQLCOM_HA_READ;
lex->sql_command = SQLCOM_HA_READ;
...
...
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