1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Automerge

This commit is contained in:
Alexey Kopytov
2009-12-13 23:57:57 +03:00
11 changed files with 743 additions and 25 deletions

View File

@@ -189,6 +189,29 @@ public:
null_value=1;
return 0.0;
}
bool has_timestamp_args()
{
DBUG_ASSERT(fixed == TRUE);
for (uint i= 0; i < arg_count; i++)
{
if (args[i]->type() == Item::FIELD_ITEM &&
args[i]->field_type() == MYSQL_TYPE_TIMESTAMP)
return TRUE;
}
return FALSE;
}
/*
We assume the result of any function that has a TIMESTAMP argument to be
timezone-dependent, since a TIMESTAMP value in both numeric and string
contexts is interpreted according to the current timezone.
The only exception is UNIX_TIMESTAMP() which returns the internal
representation of a TIMESTAMP argument verbatim, and thus does not depend on
the timezone.
*/
virtual bool is_timezone_dependent_processor(uchar *bool_arg)
{
return has_timestamp_args();
}
};