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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
a9aebd43
Commit
a9aebd43
authored
Nov 22, 2002
by
venu@myvenu.com
Browse files
Options
Browse Files
Download
Plain Diff
protocol merge
parents
1c8e36d5
b74c43f4
Changes
9
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
403 additions
and
282 deletions
+403
-282
libmysql/errmsg.c
libmysql/errmsg.c
+3
-3
libmysql/libmysql.c
libmysql/libmysql.c
+194
-111
libmysql/libmysql.def
libmysql/libmysql.def
+18
-2
sql/item.cc
sql/item.cc
+6
-11
sql/item.h
sql/item.h
+7
-6
sql/mysql_priv.h
sql/mysql_priv.h
+1
-1
sql/sql_class.h
sql/sql_class.h
+1
-2
sql/sql_error.cc
sql/sql_error.cc
+1
-1
sql/sql_prepare.cc
sql/sql_prepare.cc
+172
-145
No files found.
libmysql/errmsg.c
View file @
a9aebd43
...
...
@@ -59,7 +59,7 @@ const char *client_errors[]=
"No parameters exists in the statement"
,
"Invalid parameter number"
,
"Can't send long data for non string or binary data types (parameter: %d)"
,
"Using
not
supported parameter type: %d (parameter: %d)"
"Using
un
supported parameter type: %d (parameter: %d)"
"Shared memory (%lu)"
,
"Can't open shared memory. Request event don't create (%lu)"
,
"Can't open shared memory. Answer event don't create (%lu)"
,
...
...
@@ -113,7 +113,7 @@ const char *client_errors[]=
"No parameters exists in the statement"
,
"Invalid parameter number"
,
"Can't send long data for non string or binary data types (parameter: %d)"
,
"Using
not
supported parameter type: %d (parameter: %d)"
"Using
un
supported parameter type: %d (parameter: %d)"
"Shared memory (%lu)"
,
"Can't open shared memory. Request event don't create (%lu)"
,
"Can't open shared memory. Answer event don't create (%lu)"
,
...
...
@@ -165,7 +165,7 @@ const char *client_errors[]=
"No parameters exists in the statement"
,
"Invalid parameter number"
,
"Can't send long data for non string or binary data types (parameter: %d)"
,
"Using
not
supported parameter type: %d (parameter: %d)"
"Using
un
supported parameter type: %d (parameter: %d)"
"Shared memory (%lu)"
,
"Can't open shared memory. Request event don't create (%lu)"
,
"Can't open shared memory. Answer event don't create (%lu)"
,
...
...
libmysql/libmysql.c
View file @
a9aebd43
This diff is collapsed.
Click to expand it.
libmysql/libmysql.def
View file @
a9aebd43
...
...
@@ -102,6 +102,22 @@ EXPORTS
mysql_add_slave
mysql_warning_count
mysql_warnings
mysql_prepare
mysql_execute
mysql_param_count
mysql_bind_param
mysql_bind_result
mysql_prepare_result
mysql_stmt_close
mysql_stmt_error
mysql_stmt_errno
mysql_fetch
mysql_send_long_data
mysql_multi_query
mysql_next_result
mysql_commit
mysql_rollback
mysql_autocommit
...
...
sql/item.cc
View file @
a9aebd43
...
...
@@ -315,32 +315,27 @@ void Item_param::set_null()
void
Item_param
::
set_int
(
longlong
i
)
{
int_value
=
(
longlong
)
i
;
item_result_type
=
INT_RESULT
;
item_type
=
INT_ITEM
;
}
void
Item_param
::
set_double
(
double
value
)
{
real_value
=
value
;
item_result_type
=
REAL_RESULT
;
item_type
=
REAL_ITEM
;
}
void
Item_param
::
set_value
(
const
char
*
str
,
uint
length
,
CHARSET_INFO
*
cs
)
void
Item_param
::
set_value
(
const
char
*
str
,
uint
length
)
{
str_value
.
set
(
str
,
length
,
cs
);
item_result_type
=
STRING_RESULT
;
str_value
.
set
(
str
,
length
,
thd_charset
());
item_type
=
STRING_ITEM
;
}
void
Item_param
::
set_longdata
(
const
char
*
str
,
ulong
length
,
CHARSET_INFO
*
cs
)
void
Item_param
::
set_longdata
(
const
char
*
str
,
ulong
length
)
{
/* TODO: Fix this for binary handling by making use of
buffer_type..
*/
str_value
.
append
(
str
,
length
);
long_data_supplied
=
1
;
}
...
...
sql/item.h
View file @
a9aebd43
...
...
@@ -186,8 +186,8 @@ class Item_param :public Item
Item_param
(
char
*
name_par
=
0
)
{
name
=
name_par
?
name_par
:
(
char
*
)
"?"
;
long_data_supplied
=
false
;
item_type
=
STRING_ITEM
;
long_data_supplied
=
false
;
item_type
=
STRING_ITEM
;
item_result_type
=
STRING_RESULT
;
}
enum
Type
type
()
const
{
return
item_type
;
}
...
...
@@ -199,12 +199,13 @@ class Item_param :public Item
void
set_null
();
void
set_int
(
longlong
i
);
void
set_double
(
double
i
);
void
set_value
(
const
char
*
str
,
uint
length
,
CHARSET_INFO
*
cs
);
void
set_long_str
(
const
char
*
str
,
ulong
length
,
CHARSET_INFO
*
cs
);
void
set_long_binary
(
const
char
*
str
,
ulong
length
,
CHARSET_INFO
*
cs
);
void
set_longdata
(
const
char
*
str
,
ulong
length
,
CHARSET_INFO
*
cs
);
void
set_value
(
const
char
*
str
,
uint
length
);
void
set_long_str
(
const
char
*
str
,
ulong
length
);
void
set_long_binary
(
const
char
*
str
,
ulong
length
);
void
set_longdata
(
const
char
*
str
,
ulong
length
);
void
set_long_end
();
void
reset
()
{}
void
(
*
setup_param_func
)(
Item_param
*
param
,
uchar
**
pos
);
enum
Item_result
result_type
()
const
{
return
item_result_type
;
}
Item
*
new_item
()
{
return
new
Item_param
(
name
);
}
...
...
sql/mysql_priv.h
View file @
a9aebd43
...
...
@@ -512,7 +512,7 @@ int mysqld_show_column_types(THD *thd);
int
mysqld_help
(
THD
*
thd
,
const
char
*
text
);
/* sql_prepare.cc */
int
compare_prep_stmt
(
PREP_STMT
*
a
,
PREP_STMT
*
b
,
void
*
not_used
);
int
compare_prep_stmt
(
void
*
not_used
,
PREP_STMT
*
stmt
,
ulong
*
key
);
void
free_prep_stmt
(
PREP_STMT
*
stmt
,
TREE_FREE
mode
,
void
*
not_used
);
bool
mysql_stmt_prepare
(
THD
*
thd
,
char
*
packet
,
uint
packet_length
);
void
mysql_stmt_execute
(
THD
*
thd
,
char
*
packet
);
...
...
sql/sql_class.h
View file @
a9aebd43
...
...
@@ -325,7 +325,7 @@ typedef struct st_prep_stmt
uint
param_count
;
uint
last_errno
;
char
last_error
[
MYSQL_ERRMSG_SIZE
];
bool
error_in_prepare
,
long_data_used
;
bool
error_in_prepare
,
long_data_used
,
param_inited
;
}
PREP_STMT
;
...
...
@@ -510,7 +510,6 @@ class THD :public ilink {
bool
safe_to_cache_query
;
bool
volatile
killed
;
bool
prepare_command
;
Item_param
*
params
;
// Pointer to array of params
/*
If we do a purge of binary logs, log index info of the threads
...
...
sql/sql_error.cc
View file @
a9aebd43
...
...
@@ -127,7 +127,7 @@ static const char *warning_level_names[]= {"Note", "Warning", "Error", "?"};
my_bool
mysqld_show_warnings
(
THD
*
thd
,
ulong
levels_to_show
)
{
List
<
Item
>
field_list
;
DBUG_ENTER
(
"mysqld_show_
error
s"
);
DBUG_ENTER
(
"mysqld_show_
warning
s"
);
field_list
.
push_back
(
new
Item_empty_string
(
"Level"
,
7
));
field_list
.
push_back
(
new
Item_int
(
"Code"
,
0
,
4
));
...
...
sql/sql_prepare.cc
View file @
a9aebd43
This diff is collapsed.
Click to expand it.
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