Skip to content

MYSQL_RES_FIELD_T

Returns mysql response field object. It allows to access properties of

individual attributes of the query response.

This topic lists the expressions that are provided by this class.

CATALOG

returns the Catalog name of the column.

Returns: text_t

CHAR_SET

returns charset of the column.

Returns: mysql_charset_e

DATATYPE

returns datatype of the column.

possible values in Hex

0x00 DECIMAL

0x01 TINY

0x02 SHORT

0x03 LONG

0x04 FLOAT

0x05 DOUBLE

0x06 NULL

0x07 TIMESTAMP

0x08 LONGLONG

0x09 INT24

0x0a DATE

0x0b TIME

0x0c DATETIME

0x0d YEAR

0x0e NEWDATE

0x0f VARCHAR (new in MySQL 5.0)

0x10 BIT (new in MySQL 5.0)

0xf6 NEWDECIMAL (new in MYSQL 5.0)

0xf7 ENUM

0xf8 SET

0xf9 TINY_BLOB

0xfa MEDIUM_BLOB

0xfb LONG_BLOB

0xfc BLOB

0xfd VAR_STRING

0xfe STRING

0xff GEOMETRY

Returns: mysql_res_field_datatype_e

DB

returns the database name of the column.

Returns: text_t

DECIMALS

The number of positions after the decimal point if the type is

DECIMAL or NUMERIC.

Returns: num_at

FLAGS

returns flag values of the column.

The possible flag values (in hexadec)

0001 NOT_NULL_FLAG

0002 PRI_KEY_FLAG

0004 UNIQUE_KEY_FLAG

0008 MULTIPLE_KEY_FLAG

0010 BLOB_FLAG

0020 UNSIGNED_FLAG

0040 ZEROFILL_FLAG

0080 BINARY_FLAG

0100 ENUM_FLAG

0200 AUTO_INCREMENT_FLAG

0400 TIMESTAMP_FLAG

0800 SET_FLAG

Returns: num_at

LENGTH

returns length of the column. The value given here may be

larger than the actual length, for example an instance of a

VARCHAR(2) column may have only 1 character in it.

Returns: num_at

NAME

returns alias name of the column (table attribute).

Returns: text_t

ORIGINAL_NAME

returns alias name of the column (table attribute).

Returns: text_t

ORIGINAL_TABLE

returns table name of the column.

Returns: text_t

TABLE

returns alias table name of the column.

Returns: text_t