FireDAC.Phys.SQLiteVDataSet.TFDLocalSQL

From RAD Studio API Documentation
Jump to: navigation, search

FireDAC.Comp.Client.TFDCustomLocalSQLFireDAC.Stan.Intf.TFDComponentSystem.Classes.TComponentSystem.Classes.TPersistentSystem.TObjectTFDLocalSQL

Delphi

TFDLocalSQL = class(TFDCustomLocalSQL)

C++

class PASCALIMPLEMENTATION TFDLocalSQL : public Firedac::Comp::Client::TFDCustomLocalSQL

Properties

Type Visibility Source Unit Parent
class public
FireDAC.Phys.SQLiteVDataSet.pas
FireDAC.Phys.SQLiteVDataSet.hpp
FireDAC.Phys.SQLiteVDataSet FireDAC.Phys.SQLiteVDataSet

Description

The class implementing the SQLite-based Local SQL engine.

The Connection property points to a SQLite connection object which will provide the ability to execute the Local SQL commands. To activate the engine, set Active to True.

The FireDAC datasets can be registered with the engine by setting their LocalSQL properties. FireDAC and non-FireDAC datasets can be registered with the engine using the DataSets collection property. To remove the dataset, delete the corresponding collection item. To dynamically discover and register datasets, use the OnGetDataSet event handler.

To group the dataset objects into a schema, set the SchemaName property. To disable the dataset cloning or copying, set the MultipleCursors property to False. To enable events of a TDataSource associated with a base dataset, set DisableControls to False. To exclude invisible fields from the Local SQL result sets, set IncludeHiddenFields to False.

Example

FDConnection1.DriverName := 'SQLite';
FDLocalSQL1.Connection := FDConnection1;

FDLocalSQL1.SchemaName := 'orders';

FDLocalSQL1.DataSets.Add.DataSet := adoQOrders;
FDLocalSQL1.DataSets.Add.DataSet := qDetails;

FDQuery1.Connection := FDConnection1;
FDQuery1.Open('select * from orders.adoQOrders o left join orders.qDetails d on o.OrderID = d.OrderID');

See Also