|
Spec-Zone .ru
спецификации, руководства, описания, API
|
MYSQL_FIELD *mysql_fetch_field_direct(MYSQL_RES *result, unsigned int fieldnr)
Given a field number fieldnr for a column within a result set, returns that
column's field definition as a MYSQL_FIELD structure. Use this function to retrieve
the definition for an arbitrary column. Specify a value for fieldnr in the range
from 0 to mysql_num_fields(result)-1.
The MYSQL_FIELD structure for the specified column.
None.
unsigned int num_fields;unsigned int i;MYSQL_FIELD *field;num_fields = mysql_num_fields(result);for(i = 0; i < num_fields; i++){ field = mysql_fetch_field_direct(result, i); printf("Field %u is %s\n", i, field->name);}