MYSQL_FIELD *mysql_fetch_fields(MYSQL_RES
*result)
Описание
Возвращает массив всех структур
MYSQL_FIELD для
результирующего набора данных.
Каждая структура предоставляет
определение данного поля в одном
столбце результирующего набора.
Возвращаемые значения
Массив структур MYSQL_FIELD
для всех столбцов
результирующего набора.
Ошибки
Нет.
Пример
unsigned int num_fields;
unsigned int i;
MYSQL_FIELD *fields;
num_fields = mysql_num_fields(result);
fields = mysql_fetch_fields(result);
for(i = 0; i < num_fields; i++)
{
printf("Field %u is %s\n", i, fields[i].name);
}
This is a translation of the MySQL Reference Manual that can be found at dev.mysql.com. The original Reference Manual is in English, and this translation is not necessarily as up to date as the English version.
© 1995-2005 MySQL AB. All rights reserved.
