My Project
|
Public Member Functions | |
Field_real (uchar *ptr_arg, uint32 len_arg, uchar *null_ptr_arg, uchar null_bit_arg, utype unireg_check_arg, const char *field_name_arg, uint8 dec_arg, bool zero_arg, bool unsigned_arg) | |
type_conversion_status | store_decimal (const my_decimal *) |
type_conversion_status | store_time (MYSQL_TIME *ltime, uint8 dec) |
my_decimal * | val_decimal (my_decimal *) |
bool | get_date (MYSQL_TIME *ltime, uint fuzzydate) |
bool | get_time (MYSQL_TIME *ltime) |
bool | truncate (double *nr, double max_length) |
uint32 | max_display_length () |
virtual const uchar * | unpack (uchar *to, const uchar *from, uint param_data, bool low_byte_first) |
virtual uchar * | pack (uchar *to, const uchar *from, uint max_length, bool low_byte_first) |
Public Attributes | |
my_bool | not_fixed |
uchar * Field_real::pack | ( | uchar * | to, |
const uchar * | from, | ||
uint | max_length, | ||
bool | low_byte_first | ||
) | [virtual] |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Reimplemented from Field.
Reimplemented in Field_decimal.
type_conversion_status Field_real::store_decimal | ( | const my_decimal * | val | ) | [virtual] |
Storing decimal in integer fields.
val | value for storing |
TYPE_OK | Storage of value went fine without warnings or errors |
!TYPE_OK | Warning/error as indicated by type_conversion_status enum value |
Reimplemented from Field_num.
type_conversion_status Field_real::store_time | ( | MYSQL_TIME * | ltime, |
uint8 | dec_arg | ||
) | [virtual] |
Store MYSQL_TIME value with the given amount of decimal digits into a field.
Note, the "dec" parameter represents number of digits of the Item that previously created the MYSQL_TIME value. It's needed when we store the value into a CHAR/VARCHAR/TEXT field to display the proper amount of fractional digits. For other field types the "dec" value does not matter and is ignored.
ltime | Time, date or datetime value. |
dec | Number of decimals in ltime. |
false | on success |
true | on error |
This is called when storing a date in a string.
Reimplemented from Field_num.
const uchar * Field_real::unpack | ( | uchar * | to, |
const uchar * | from, | ||
uint | param_data, | ||
bool | low_byte_first | ||
) | [virtual] |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Reimplemented from Field.
Reimplemented in Field_decimal.
my_decimal * Field_real::val_decimal | ( | my_decimal * | decimal_value | ) | [virtual] |
Return decimal value of integer field.
decimal_value | buffer for storing decimal value |
Reimplemented from Field_num.