mirror of
https://github.com/MariaDB/server.git
synced 2025-08-09 22:24:09 +03:00
Fix for Bug#4030 "Client side conversion string -> date type doesn't
work (prepared statements)" and after-review fixes: - str_to_TIME renamed to str_to_datetime to pair with str_to_time - functions str_to_time and str_to_TIME moved to sql-common - send_data_str now supports MYSQL_TYPE_TIME, MYSQL_TIME_DATE, MYSQL_TIME_DATETIME types of user input buffers. - few more comments in the client library - a test case added.
This commit is contained in:
@@ -55,6 +55,7 @@ typedef int my_socket;
|
||||
#endif /* _global_h */
|
||||
|
||||
#include "mysql_com.h"
|
||||
#include "mysql_time.h"
|
||||
#include "mysql_version.h"
|
||||
#include "typelib.h"
|
||||
|
||||
@@ -533,23 +534,6 @@ enum enum_mysql_stmt_state
|
||||
MYSQL_STMT_FETCH_DONE
|
||||
};
|
||||
|
||||
/*
|
||||
client TIME structure to handle TIME, DATE and TIMESTAMP directly in
|
||||
binary protocol
|
||||
*/
|
||||
enum mysql_st_timestamp_type { MYSQL_TIMESTAMP_NONE, MYSQL_TIMESTAMP_DATE,
|
||||
MYSQL_TIMESTAMP_FULL, MYSQL_TIMESTAMP_TIME };
|
||||
|
||||
typedef struct mysql_st_time
|
||||
{
|
||||
unsigned int year,month,day,hour,minute,second;
|
||||
unsigned long second_part;
|
||||
my_bool neg;
|
||||
|
||||
enum mysql_st_timestamp_type time_type;
|
||||
|
||||
} MYSQL_TIME;
|
||||
|
||||
|
||||
/* bind structure */
|
||||
typedef struct st_mysql_bind
|
||||
|
Reference in New Issue
Block a user