September 2001
Intermediate to advanced
768 pages
32h 45m
English
string mysql_field_type(mysql result result_handle, int field_offset)
| result_handle | Result handle returned by mysql_db_query() or mysql_query() |
| field_offset | Field offset to use |
Gets the type of the specified field.
Returns:
String; FALSE on error
Description:
mysql_field_type() returns the type of the specified field in a query. The field_offset argument specifies the desired field. Field offsets start at 0.
The types returned by this function are similar but not identical to MySQL’s column types. If the column value is generated by an expression, the type of the result determines the type of the column. For example, suppose this is the query: SELECT count(user);
The type would be int.
The following table lists the types. ...
Read now
Unlock full access