summaryrefslogtreecommitdiff
path: root/sql/item_create.cc
diff options
context:
space:
mode:
authorMikael Ronstrom <mikael@mysql.com>2009-10-28 18:22:36 +0100
committerMikael Ronstrom <mikael@mysql.com>2009-10-28 18:22:36 +0100
commit072c13d9395b6a3f3a472633d6e817db9215d81e (patch)
tree0891f6df26609fa66b89a4cc8faa8079ec21f6f3 /sql/item_create.cc
parentcd6e15989044e5d4a708a6ee191bcd3c13dc0071 (diff)
parent10fed1aca0096acb135c2065233e84d61b00b9cf (diff)
downloadmariadb-git-072c13d9395b6a3f3a472633d6e817db9215d81e.tar.gz
Merged WL#3352 into mysql-next-mr
Diffstat (limited to 'sql/item_create.cc')
-rw-r--r--sql/item_create.cc22
1 files changed, 22 insertions, 0 deletions
diff --git a/sql/item_create.cc b/sql/item_create.cc
index 2f80d16b928..5e419d40152 100644
--- a/sql/item_create.cc
+++ b/sql/item_create.cc
@@ -2052,6 +2052,18 @@ protected:
virtual ~Create_func_to_days() {}
};
+class Create_func_to_seconds : public Create_func_arg1
+{
+public:
+ virtual Item* create(THD *thd, Item *arg1);
+
+ static Create_func_to_seconds s_singleton;
+
+protected:
+ Create_func_to_seconds() {}
+ virtual ~Create_func_to_seconds() {}
+};
+
#ifdef HAVE_SPATIAL
class Create_func_touches : public Create_func_arg2
@@ -4505,6 +4517,15 @@ Create_func_to_days::create(THD *thd, Item *arg1)
}
+Create_func_to_seconds Create_func_to_seconds::s_singleton;
+
+Item*
+Create_func_to_seconds::create(THD *thd, Item *arg1)
+{
+ return new (thd->mem_root) Item_func_to_seconds(arg1);
+}
+
+
#ifdef HAVE_SPATIAL
Create_func_touches Create_func_touches::s_singleton;
@@ -4942,6 +4963,7 @@ static Native_func_registry func_array[] =
{ { C_STRING_WITH_LEN("TIME_TO_SEC") }, BUILDER(Create_func_time_to_sec)},
{ { C_STRING_WITH_LEN("TOUCHES") }, GEOM_BUILDER(Create_func_touches)},
{ { C_STRING_WITH_LEN("TO_DAYS") }, BUILDER(Create_func_to_days)},
+ { { C_STRING_WITH_LEN("TO_SECONDS") }, BUILDER(Create_func_to_seconds)},
{ { C_STRING_WITH_LEN("UCASE") }, BUILDER(Create_func_ucase)},
{ { C_STRING_WITH_LEN("UNCOMPRESS") }, BUILDER(Create_func_uncompress)},
{ { C_STRING_WITH_LEN("UNCOMPRESSED_LENGTH") }, BUILDER(Create_func_uncompressed_length)},