omron — ODBCQuery

Appendix: Built-in Scripting Language Syntax ODBCOpen( strDsn , strUser , strPassw , strTable , strFilter , strSort ) strDsn The name of the data source. strUser The user name. strPassw The password. strTable The name of the database table strFilter The SQL WHERE clause. strSort The SQL ORDER BY clause. Returned value Notes This function does not read or write any data; it simply creates a handle to manipulate the database. You must bind the columns using the ODBCBindCol function, and then you must call the ODBCQuery function to retrieve the first record. Examples ODBCQuery Retrieves the currently selected record from a database.

Syntax ODBCQuery( numHandler ) numHandler The handler returned by the ODBCOpen function. Returned value Page 588 InduSoft Web Studio n On success, returns the handler to identify the database −1 Invalid parameter −2 DSN or TableName contain an empty string Tag Name Expression Tag ODBCOpen( "MyDSNFile", "Alex", "", "Table1", "Name='Mayer'", "Name ASC" ) Tag ODBCOpen( "DSNFileName", "Robert", "Robot", "Table1", "", "" ) Function Group Execution Windows Embedded Thin Client ODBCQuery ODBC Synchronous Supported Not supported Executed on Server 0 Success 1 Invalid handler 2 No columns bound 3 Cannot open database 4 Cannot restart database