ifx_fieldtypes

ifx_fieldtypes -- List of Informix SQL fields

Description

array ifx_fieldtypes(int result_id);

Returns an associative array with fieldnames as key and the SQL fieldtypes as data for query with result_id. Returns FALSE on error.

Example 1. Fielnames and SQL fieldtypes

  1 
  2 $types = ifx_fieldtypes ($resultid);
  3 if (! isset ($types)) {
  4   ... error ...
  5 }
  6 for ($i = 0; $i < count($types); $i++) {
  7     $fname = key($types);
  8     printf("%s :\t type =  %s\n", $fname, $types[$fname]);
  9     next($types);
 10 }
 11