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

SQL Anywhere 11.0.1 (Français) » SQL Anywhere Server - Programming » SQL Anywhere Data Access APIs » SQL Anywhere for Ruby » SQL Anywhere Ruby API

 

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 )