i5_num_fields

 

Get the numbers of fields for resource.

 

int i5_num_fields (

resource result/query )

 

Parameters

 

result

Resource describing file or other record set.

 

 

Returns:

Number of fields.

 

I5_ERR_PHP_HDLDFT

256

No default connection found.

I5_ERR_PHP_OPTIONSTYPE

259

The type of " I5_OPTIONS_ALIAS" option must be x and not x

I5_ERR_PHP_OPTIONSNUMBER

260

Option number -1 is unknown.

 

 

Example

 

$file = i5_open("EASYCOM/s_customer");

if (is_bool($file))

trigger_error("i5_open error : ".i5_errormsg(), E_USER_ERROR);

echo "s_customer file have ". i5_num_fields($file) . " fields";

i5_free_file($file);

 

See also

 

i5_info

i5_num_rows