#include <item_timefunc.h>
Inheritance diagram for Item_func_maketime:


Public Member Functions | |
| Item_func_maketime (Item *a, Item *b, Item *c) | |
| String * | val_str (String *str) |
| const char * | func_name () const |
| enum_field_types | field_type () const |
| void | fix_length_and_dec () |
| Field * | tmp_table_field (TABLE *table) |
| bool | check_partition_func_processor (byte *bool_arg) |
Definition at line 878 of file item_timefunc.h.
| enum_field_types Item_func_maketime::field_type | ( | ) | const [inline, virtual] |
Reimplemented from Item.
Definition at line 885 of file item_timefunc.h.
References MYSQL_TYPE_TIME.
00885 { return MYSQL_TYPE_TIME; }
| void Item_func_maketime::fix_length_and_dec | ( | ) | [inline, virtual] |
Implements Item_result_field.
Definition at line 886 of file item_timefunc.h.
References Item::decimals, Item::max_length, MAX_TIME_WIDTH, and MY_CHARSET_BIN_MB_MAXLEN.
00887 { 00888 decimals=0; 00889 max_length=MAX_TIME_WIDTH*MY_CHARSET_BIN_MB_MAXLEN; 00890 }
| const char* Item_func_maketime::func_name | ( | ) | const [inline, virtual] |
Reimplemented from Item_func.
Definition at line 891 of file item_timefunc.h.
References Item::tmp_table_field_from_field_type().
00892 { 00893 return tmp_table_field_from_field_type(table, 0); 00894 }
Here is the call graph for this function:

Implements Item.
Definition at line 2689 of file item_timefunc.cc.
References String::alloc(), Item_func::args, DBUG_ASSERT, Item::fixed, st_mysql_time::hour, make_time(), st_mysql_time::minute, st_mysql_time::neg, Item::null_value, st_mysql_time::second, and Item_str_func::val_int().
02690 { 02691 DBUG_ASSERT(fixed == 1); 02692 TIME ltime; 02693 02694 long hour= (long) args[0]->val_int(); 02695 long minute= (long) args[1]->val_int(); 02696 long second= (long) args[2]->val_int(); 02697 02698 if ((null_value=(args[0]->null_value || 02699 args[1]->null_value || 02700 args[2]->null_value || 02701 minute > 59 || minute < 0 || 02702 second > 59 || second < 0 || 02703 str->alloc(19)))) 02704 return 0; 02705 02706 ltime.neg= 0; 02707 if (hour < 0) 02708 { 02709 ltime.neg= 1; 02710 hour= -hour; 02711 } 02712 ltime.hour= (ulong) hour; 02713 ltime.minute= (ulong) minute; 02714 ltime.second= (ulong) second; 02715 make_time((DATE_TIME_FORMAT *) 0, <ime, str); 02716 return str; 02717 }
Here is the call graph for this function:

1.4.7

