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.
Added basic per-thread time zone functionality (based on public
domain elsie-code). Now user can select current time zone
(from the list of time zones described in system tables).
All NOW-like functions honor this time zone, values of TIMESTAMP
type are interpreted as values in this time zone, so now
our TIMESTAMP type behaves similar to Oracle's TIMESTAMP WITH
LOCAL TIME ZONE (or proper PostgresSQL type).
WL#1266 "CONVERT_TZ() - basic time with time zone conversion
function".
Fixed problems described in Bug #2336 (Different number of warnings
when inserting bad datetime as string or as number). This required
reworking of datetime realted warning hadling (they now generated
at Field object level not in conversion functions).
Optimization: Now Field class descendants use table->in_use member
instead of current_thd macro.
after Monty's review.
- Item_param was rewritten.
- it turns out that we can't convert string data to character set of
connection on the fly, because they first should be written to the binary
log.
To support efficient conversion we need to rewrite prepared statements
binlogging code first.
Output TIMESTAMP in 4.1 format for 4.1 tables (or for TIMESTAMP(19)) (portability fix)
Fixed that INTERVAL can handle big integers. (Bug #3498)
Fixed that hostname="" works identical as hostname="%" for table/column grants (Bug #3473)
Item_func_from_days::get_date didn't change 'hr', 'min' and some
other fields of incoming ltime, so they got random values.
bzeroing of the ltime added
New formats added for 'week()' function and 'default_week_format' option(4 - 7).
Next formats is supported now:
*Value* *Meaning*
`0' Week starts on Sunday; First Sunday of the year starts week 1.
Week() returns 0-53.
`1' Week starts on Monday; Weeks numbered according to ISO 8601:1988.
Week() returns 0-53.
`2' Week starts on Sunday; First Sunday of the year starts week 1.
Week() returns 1-53.
`3' Week starts on Monday; Weeks numbered according to ISO 8601:1988.
Week() returns 1-53.
`4' Week starts on Sunday; Weeks numbered according to ISO 8601:1988.
Week() returns 0-53.
`5' Week starts on Monday; First Monday of the year starts week 1.
Week() returns 0-53.
`6' Week starts on Sunday; Weeks numbered according to ISO 8601:1988.
Week() returns 1-53.
`7' Week starts on Monday; First Monday of the year starts week 1.
Week() returns 1-53.
Fixed compiler warnings (a lot of hidden variables detected by the Forte compiler)
Added a lot of 'version_xxx' strings to 'show variables'
Prevent copying of TMP_TABLE_PARAM (This caused core dump bug on Solaris)
Fixed problem with printing sub selects to debug log
Cleaned up (and disabled part of) date/time/datetime format patch. One can't anymore change default read/write date/time/formats.
This is becasue the non standard datetime formats can't be compared as strings and MySQL does still a lot of datetime comparisons as strings
Changed flag argument to str_to_TIME() and get_date() from bool to uint
Removed THD from str_to_xxxx functions and Item class.
Fixed core dump when doing --print-defaults
Move some common string functions to strfunc.cc
Dates as strings are now of type my_charset_bin instead of default_charset()
Introduce IDENT_QUOTED to not have to create an extra copy of simple identifiers (all chars < 128)
Removed xxx_FORMAT_TYPE enums and replaced them with the old TIMESTAMP_xxx enums
Renamed some TIMESTAMP_xxx enums to more appropriate names
Use defines instead of integers for date/time/datetime string lengths
Added to build system and use the new my_strtoll10() function.