Promotic

OpenSQL - property of the PmaDatabase object

Description:
SQL statement of the SELECT type on open
Syntax:
String OpenSQL
Note:
Property access for read and write. The default value of this property is defined in the "SQL statement during opening" configurator of this object.
 
The SQL statement specifies which rows, columns from the table will be read by the object.
The property is used when calling the Open method only if the "Open table using the SQL statement SELECT" configurator configurator is checked. Otherwise the Table property is used and the whole content of the table is read.
See also:
- PmaDatabase.Open (method)
Example:
The "Open table using the SQL statement SELECT" configurator is checked
JavaScriptVBScriptSelect and copy to clipboard

if (oDb.IsOpen())
{
oDb.CloseTable();
}

oDb.OpenSQL = "SELECT * FROM Table WHERE MyColumn BETWEEN 10 AND 100";
oDb.Open();
// ... do something with the query "SELECT * FROM Table ..."
oDb.CloseTable();

oDb.OpenSQL = "SELECT MyColumn1, MyColumn2 FROM Table WHERE MyColumn1 > 10";
oDb.Open();
// ... do something with the query "SELECT MyColumn1, MyColumn2 FROM Table ..."
PROMOTIC 9.0.27 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r.o.