sqlany_num_params

Returns the number of parameters that are expected for a prepared statement.

Syntax
sqlany_num_params ( $stmt )
Parameters
  • $stmt   A statement object returned by the successful execution of sqlany_prepare.

Returns

Returns a scalar value that is the number of parameters in a prepared statement, or -1 on a failure.

See also
Example
stmt = api.sqlany_prepare(conn, "UPDATE Contacts
      SET Contacts.ID = Contacts.ID + 1000
      WHERE Contacts.ID >= ?" )
num_params = api.sqlany_num_params( stmt )