[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
[Properties (by Name)] [Methods (by Name)] [Events (by Name)]
Class to handle SQL commands (with or without result set)
Source position: sqldb.pp line 626
type TSQLQuery = class(TCustomSQLQuery) |
||
public |
||
property SchemaType: TSchemaType; |
|
Schema type |
property StatementType: TStatementType; |
|
SQL statement type |
published |
||
property MaxIndexesCount: Integer; |
|
Maximum allowed number of indexes. |
property FieldDefs: TFieldDefs; |
|
Definitions of available fields in the underlying database |
property Active: Boolean; |
|
Is the dataset open or closed. |
property AutoCalcFields: Boolean; |
|
How often should the value of calculated fields be calculated |
property Filter: string; |
|
Filter to apply to the data in memory. |
property Filtered: Boolean; |
|
Is the filter active or not. |
property AfterCancel: TDataSetNotifyEvent; |
|
Event triggered after a Cancel operation. |
property AfterClose: TDataSetNotifyEvent; |
|
Event triggered after the dataset is closed |
property AfterDelete: TDataSetNotifyEvent; |
|
Event triggered after a successful Delete operation. |
property AfterEdit: TDataSetNotifyEvent; |
|
Event triggered after the dataset is put in edit mode. |
property AfterInsert: TDataSetNotifyEvent; |
|
Event triggered after the dataset is put in insert mode. |
property AfterOpen: TDataSetNotifyEvent; |
|
Event triggered after the dataset is opened. |
property AfterPost: TDataSetNotifyEvent; |
|
Event called after changes have been posted to the underlying database |
property AfterRefresh: TDataSetNotifyEvent; |
|
Event triggered after the data has been refreshed. |
property AfterScroll: TDataSetNotifyEvent; |
|
Event triggered after the cursor has changed position. |
property BeforeCancel: TDataSetNotifyEvent; |
|
Event triggered before a Cancel operation. |
property BeforeClose: TDataSetNotifyEvent; |
|
Event triggered before the dataset is closed. |
property BeforeDelete: TDataSetNotifyEvent; |
|
Event triggered before a Delete operation. |
property BeforeEdit: TDataSetNotifyEvent; |
|
Event triggered before the dataset is put in edit mode. |
property BeforeInsert: TDataSetNotifyEvent; |
|
Event triggered before the dataset is put in insert mode. |
property BeforeOpen: TDataSetNotifyEvent; |
|
Event triggered before the dataset is opened. |
property BeforePost: TDataSetNotifyEvent; |
|
Event called before changes are posted to the underlying database |
property BeforeRefresh: TDataSetNotifyEvent; |
|
Event triggered before the data is refreshed. |
property BeforeScroll: TDataSetNotifyEvent; |
|
Event triggered before the cursor changes position. |
property OnCalcFields: TDataSetNotifyEvent; |
|
Event triggered when values for calculated fields must be computed. |
property OnDeleteError: TDataSetErrorEvent; |
|
Event triggered when a delete operation fails. |
property OnEditError: TDataSetErrorEvent; |
|
Event triggered when an edit operation fails. |
property OnFilterRecord: TFilterRecordEvent; |
|
Event triggered to filter records. |
property OnNewRecord: TDataSetNotifyEvent; |
|
Event triggered when a new record is created. |
property OnPostError: TDataSetErrorEvent; |
|
Event triggered when a post operation fails. |
|
The TSQLConnection instance on which to execute SQL Statements |
|
property Transaction: TDBTransaction; |
|
Transaction in which to execute SQL statements |
property ReadOnly: Boolean; |
||
property SQL: TStringList; |
|
The SQL statement to execute |
property InsertSQL: TStringList; |
|
Statement to be used when inserting a new row in the database |
property UpdateSQL: TStringList; |
|
Statement to be used when updating an existing row in the database |
property DeleteSQL: TStringList; |
|
Statement to be used when deleting a new row in the database |
property RefreshSQL: TStringList; |
|
Refresh query to re-fetch field values after a DB update |
property IndexDefs: TIndexDefs; |
|
Index definitions for the dataset |
property Options: TSQLQueryOptions; |
|
Options controlling the behaviour of the dataset |
|
Parameters detected in the SQL statement. |
|
property ParamCheck: Boolean; |
|
Should the SQL statement be checked for parameters |
property ParseSQL: Boolean; |
|
Should the SQL statement be parsed or not |
property UpdateMode: TUpdateMode; |
|
How to create update SQL statements. |
property UsePrimaryKeyAsKey: Boolean; |
|
Should primary key fields be marked pfInKey |
property DataSource: TDataSource; |
|
Source for parameter values for unbound parameters |
property Sequence: TSQLSequence; |
|
Sequence to use for auto-generating values using a sequence |
property ServerFilter: string; |
|
Append server-side filter to SQL statement |
property ServerFiltered: Boolean; |
|
Should server-side filter be applied |
property ServerIndexDefs: TServerIndexDefs; |
|
List of indexes on the primary table of the query |
end; |
|
Class to handle SQL commands (with or without result set) |
|
| | ||
|
Custom Class to handle SQL commands (with or without result set) |
|
| | ||
|
Dataset connected to a database. |
|
| | ||
|
Dataset connected to a database. |
|
| | ||
|
Base class for records-based data-access |
|
| | ||
| | ||
| | ||
TObject |
TSQLQuery exposes the properties and some methods introduced in TCustomSQLQuery. It encapsulates a single SQL statement: it implements all the necessary #fcl.db.TDataset functionality to be able to handle a result set. It can also be used to execute a single SQL statement that does not return data, using the TCustomSQLQuery.ExecSQL method.
Typically, the TSQLQuery.Database property must be set once, the TSQLQuery.Transaction property as well. Then the TSQLQuery.SQL property can be set. Depending on the kind of SQL statement, the Open method can be used to retrieve data, or the ExecSQL method can be used to execute the SQL statement (this can be used for DDL statements, or update statements).
|
Transaction in which a TSQLQuery is handled |
|
|
An abstract class representing a connection to a SQL Database |
|
|
Execute a SQL statement that does not return a result set |
|
|
The SQL statement to execute |