On 04/11/13 18:18, Daniel-Constantin Mierla wrote:
I thought timestamp storing the unix time stamp as seconds. I see that in mysql module, MYSQL_TYPE_TIMESTAMP is considered as integer value (so expects the seconds) and MYSQL_TYPE_DATETIME is stored over a time_t by converting from date-time string.
Yes, it appears that datetime and timestamp are stored differently internally, but present the same format in SQL commands. That's good news, and suggests we can convert columns between the two at will.
I would do some basic tests to see if it works - on 32b looks like being ok. On 64b, the time_t is long int, iirc, so the sizes are different -- speaking of these, this mapping has to be reviewed anyhow, I will look closer at it when I get a chance.
Thanks!