ssCore.ADO.setSQL

Provide the raw SQL to create a result set.


Availability:

First available in version 3.0 build 2039.


Input Parameters:

sql - [Optional] - This call just sets a sesssion property so the return value can be ignored. If you got anything wrong, a real error will be returned when you try to open the table.


Output Parameters:

No output parameters.


Asynchronous Mode:

When this method is called asynchronously, a return object containing the output parameters is passed to the specified callback function.

ssCore.ADO.setSQL( paramsObject [, callbackParamsObject] [, errorParamsObject] );


Synchronous Mode:

When this method is called synchronously, a return object containing the output parameters is returned to the caller immediately.

var returnObject = ssCore.ADO.setSQL( paramsObject );


Notes:

ADO.setSQL is meant to replace calls to ADO.setFieldList, ADO.setWhere, ADO.setTable and ADO.setOrderBy. After calling ADO.setSQL, calls to these other functions will be ignored (unless the SQL statement is set to an empty string). Access to the raw SQL statement allows you to create complex, multi-table SQL queries, joins, etc.

                

Examples:

ssCore.ADO.setSQL({sql:"SELECT * FROM Customers"});