Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - Programming » SQL Anywhere PHP API » SQL Anywhere PHP API reference

sqlanywhere_identity Next Page

sqlanywhere_num_fields


Prototype

resource sqlanywhere_num_fields( resource result_identifier )

Description

Returns the number of columns (fields) the result_identifier contains.

Parameters

result_identifier    The result identifier returned by a sqlanywhere_query function.

Returns

A positive number of columns, or an error if result_identifier is not valid.

Example

This example returns a value indicating how many columns are in the result set.

$num_columns = sqlanywhere_num_fields( $result );