PHP mysqli_fetch_field_direct() 函数 PHP MySQLi 参考手册 返回结果集中某个单一字段(列)的 meta-data,并输出字段名称、表格和最大长度: 定义和用法 mysqli_fetch_field_direct() 函数从结果集中取得某个单一字段(列)的 meta-data,并作为对象返回。 语法 m
这里的fieldnr是一个整数,它代表字段在结果集中从0开始的索引,其范围应该在0到mysql_num_fields(result)减1之间,其中mysql_num_fields(result)表示结果集中列的数量。通过调用mysql_fetch_field_direct,你可以针对任意列获取其字段类型、名称、长度、是否可为空等属性信息。这个函数执行时,如果指定的...
MYSQL_FIELD * mysql_fetch_field_direct(MYSQL_RES * res, unsigned int fieldnr); res - a result set identifier returned by mysql_store_result() or mysql_use_result(). fieldnr - the field number. This value must be within the range from 0 to number of fields - 1 Description Return...
MYSQL_FIELD *f=NULL; printf("Fetching field: %d\n",field); f = mysql_fetch_field_direct(res,field); printf("char *name : %s\n",f->name); /* Name of column */ printf("char *table : %s\n",f->table); /* Table of column if column was a field */ ...
MYSQL_FIELD*mysql_fetch_field_direct(MYSQL_RES*result,unsignedintfieldnr) Description Given a field numberfieldnrfor a column within a result set, returns that column's field definition as aMYSQL_FIELDstructure. Use this function to retrieve the definition for an arbitrary column. Specify a value...
Given a field numberfieldnrfor a column within a result set, returns that column's field definition as aMYSQL_FIELDstructure. Use this function to retrieve the definition for an arbitrary column. Specify a value forfieldnrin the range from 0 tomysql_num_fields(result)-1. ...
MYSQL_FIELD*mysql_fetch_field_direct(MYSQL_RES*result,unsignedintfieldnr) Description Given a field numberfieldnrfor a column within a result set, returns that column's field definition as aMYSQL_FIELDstructure. Use this function to retrieve the definition for an arbitrary column. Specify a value...
mysqli_result::fetch_field_direct file: reference/mysqli/msqli_result/fetch-field-direct.xml The "returnvalues" section currently reads: Returns an object which contains field definition information or &false; if no field information for...
mysqli_fetch_field_direct()函数获取单个字段的元数据 定义和用法 PHP 结果对象(mysqli_result类)表示MySQL结果,由SELECT或DESCRIBE或EXPLAIN查询返回。 mysqli_fetch_field_direct()函数接受一个结果对象和一个表示字段编号的整数,并以对象的形式返回指定列/字段的定义信息。
mysql_fetch_field_direct() bug? 1050 Dave Juntgen December 19, 2005 01:04PM Re: mysql_fetch_field_direct() bug? 486 Georg Richter December 24, 2005 04:17PM Re: mysql_fetch_field_direct() bug? 511 Dave Juntgen December 26, 2005 04:39PM Re: mysql_fetch_field_direct() bug...