diff options
author | unknown <konstantin@mysql.com> | 2004-12-18 00:17:25 +0300 |
---|---|---|
committer | unknown <konstantin@mysql.com> | 2004-12-18 00:17:25 +0300 |
commit | 996352b73e60cce2458cf72ab36c49126e635997 (patch) | |
tree | 75100b91f7d8e8ab02c6fa3120b8fbb75d8e7265 /include/mysql.h | |
parent | 91a76445335eb251440e61b114b4fdbb0dba5813 (diff) | |
download | mariadb-git-996352b73e60cce2458cf72ab36c49126e635997.tar.gz |
Truncations patch: a post-review fix.
include/mysql.h:
Adding an option for data truncations feature.
libmysql/libmysql.c:
No 'smart' behaviour now for data truncations: they are always
reported, unless switched off with
mysql_options(mysql, MYSQL_REPORT_DATA_TRUNCATION, (my_bool*) &(option=1));
sql-common/client.c:
Add support for report-data-truncation variable in my.cnf
tests/client_test.c:
A test for MYSQL_REPORT_DATA_TRUNCATION option.
Diffstat (limited to 'include/mysql.h')
-rw-r--r-- | include/mysql.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/mysql.h b/include/mysql.h index cb7b4629ec0..58c314207c1 100644 --- a/include/mysql.h +++ b/include/mysql.h @@ -145,7 +145,8 @@ enum mysql_option MYSQL_OPT_PROTOCOL, MYSQL_SHARED_MEMORY_BASE_NAME, MYSQL_OPT_READ_TIMEOUT, MYSQL_OPT_WRITE_TIMEOUT, MYSQL_OPT_USE_RESULT, MYSQL_OPT_USE_REMOTE_CONNECTION, MYSQL_OPT_USE_EMBEDDED_CONNECTION, - MYSQL_OPT_GUESS_CONNECTION, MYSQL_SET_CLIENT_IP, MYSQL_SECURE_AUTH + MYSQL_OPT_GUESS_CONNECTION, MYSQL_SET_CLIENT_IP, MYSQL_SECURE_AUTH, + MYSQL_REPORT_DATA_TRUNCATION }; struct st_mysql_options { @@ -186,6 +187,8 @@ struct st_mysql_options { char *client_ip; /* Refuse client connecting to server if it uses old (pre-4.1.1) protocol */ my_bool secure_auth; + /* 0 - never report, 1 - always report (default) */ + my_bool report_data_truncation; /* function pointers for local infile support */ int (*local_infile_init)(void **, const char *, void *); |