Hi, Alexander! On Jul 05, Alexander Barkov wrote:
I thought you'll make real_type() methods to return MYSQL_TYPE_xxx values, not MYSQL_TYPE_xxx2 values. Why wouldn't that work?
I did not even consider it. This is my understanding of the things:
Field::type() is responsible for behaviour (interaction with Items). It's OK to return MYSQL_TYPE_xxx here for the MySQL56 date types.
Field::real_type() is responsible for low level format, and is used to check binary compatibility between fields.
Hmm. Then, considering your many uses of real_type_to_type() and is_timestamp_type(), I'd say that the our code seems to use Field::real_type() too much, even when one should've used Field::type(). But ok, that's an issue for another day. The patch is ok. Regards, Sergei