TDALocalDataAdapter

Overview

The TDALocalDataAdapter component forms the center of communication from the client to the server. It provides all the logic for retrieving data into TDADataTables, applying changes (Deltas) back to the server and handling any other data-related communication with the server, such as retrieving business rules scripts or schema information. Contrary to the TDARemoteDataAdapter class, the TDALocalDataAdapter only works with local services.

The usage of this class is similar to the usage of the TDARemoteDataAdapter.

Location

 

constructor Create (IDataAbstractLocalServiceAccess)  reintroduce overload beta

Creates a new instance and initializes the ServiceInstance property.

constructor Create(const aServiceInstance: IDataAbstractLocalServiceAccess)

Parameters:

  • aServiceInstance: Data Service instance that will be used to execute the TDALocalDataAdapter methods

constructor Create (string)  reintroduce overload beta

Creates a new instance and initializes the ServiceName property.

constructor Create(const aServiceName: string)

Parameters:

  • aServiceName: Name of the Data Service that will be used to execute the TDALocalDataAdapter methods

constructor Create (TComponent)  override    (declared in TDABaseDataAdapter)

Creates a new instance.

constructor Create(aOwner: TComponent)

Parameters:

  • aOwner: Owner.

ApplyUpdates  override    (declared in TDABaseDataAdapter)

Applies local updates, which are represented in the collection of data tables, back to the server and returns true if the updates were successfully applied on the server. Otherwise returns false.

function ApplyUpdates(aTables: array of TDADataTable; aRefetchAll: boolean): boolean

Parameters:

  • aTables: Input collection of data tables with updates that should be applied on the server.
  • aRefetchAll: True: the data tables reopen after applying updates on the server. False: they don't reopen. By default, this parameter equals False.

Assign  override    (declared in TDABaseDataAdapter)

Copies the contents of another, similar object.

procedure Assign(Source: TPersistent)

Parameters:

  • Source: Instance whose properties will be copied

AutoFillScripts    (declared in TDABaseDataAdapter)

Autofills business rules scripts at opening tables

property AutoFillScripts: Boolean read write

CacheSchema  protected    (declared in TDABaseDataAdapter)

Toggles whether the data adapter will maintain a local cache of the schema retrieved from the server with subsequent calls to the Schema property. If set to true, the adapter will download the schema the first time the Schema property is accessed, and subsequent accesses will return the same schema instance. If set to false (default), the schema will be re-downloaded from the server every time. You can flush any cached schema by setting this property to false and then immediately back to true, or by calling the FlushSchema method. Set this property to false when you expect frequent changes in the schema information, or when you want to update data tables to a changed server, at design time. Set it to true you want your application to only obtain the schema once and don't expect the server-side schema to change while the application is running.

property CacheSchema: boolean read write

CheckProperties  override    (declared in TDABaseDataAdapter)

Validates the data adapter properties.

procedure CheckProperties(ACheckOnlyDataStreamer: Boolean)

Parameters:

  • ACheckOnlyDataStreamer: True if only the data streamer should be checked, otherwise False. By default, this parameter equals False.

CreateTableRequestInfo  protected    (declared in TDABaseDataAdapter)

Generates TableRequestInfo based on given parameters.

function CreateTableRequestInfo(aTable: TDADataTable; aIncludeSchema: boolean; aDynamicWhereExpression: TDAWhereExpression): TableRequestInfo

Parameters:

  • aTable: datatable
  • aIncludeSchema: include schema
  • aDynamicWhereExpression: dynamic where expression

DataStreamer  protected    (declared in TDACustomDataAdapter)

Defines the type of data streamer to be used for reading and writing data from and to the network. The type of streamer assigned here must match the streamer used on the ServiceDataStreamer property of the sever in the descendant classes.

property DataStreamer: TDADataStreamer read write

DynamicSelect    (declared in TDABaseDataAdapter)

Flag indicating whether Data Adapter should perform queries using the Dynamic Select feature.

property DynamicSelect: Boolean read write

FailureBehavior    (declared in TDABaseDataAdapter)

Manages how TDABaseRemoteDataAdapter behaves when an error is encountered.

property FailureBehavior: TDAFailureBehavior read write

Fill (array of TDADataTable, array of TableRequestInfo, boolean, boolean, Boolean)  overload    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aTableRequestInfoArray: array of TableRequestInfo; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aTableRequestInfoArray: The specified collection of TableRequestInfo that contains additional parameters.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

Fill (array of TDADataTable, array of TDAWhereExpression, boolean, boolean, Boolean)  overload    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aWhereClauses: array of TDAWhereExpression; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aWhereClauses: The specified collection of where clasuses that should receive the data from the server.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

Fill (array of TDADataTable, boolean, boolean, Boolean)  overload override    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

FillSchema  override    (declared in TDABaseDataAdapter)

Retrieves schema information for all specified TDADataTables, and configures their Fields and Params setup to match the schema from the server. You can perform the same task at design-time for individual data tables by right-clicking the data table component and selecting "Retrieve DataTable Schema" from the context menu.

procedure FillSchema(aTables: array of TDADataTable; aPreserveLookupFields: boolean; aPreserveClientCalcFields: boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the schema information.
  • aPreserveLookupFields: Defines whether the collection of lookup fields should be preserved (true) or not (false). By default, this parameter equals false
  • aPreserveClientCalcFields: Defines whether the collection of calculated fields should be reserved (true) or not (false). By default, this parameter equals false

FillScripts  override    (declared in TDABaseDataAdapter)

Retrieves business rules scripts for all specified TDADataTables from the server.

procedure FillScripts(aTables: array of TDADataTable)

Parameters:


FillWithDASql (array of TDADataTable, array of string)  overload    (declared in TDABaseDataAdapter)

The method fills given data tables with the data from the server with a glance of SQL strings using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTables: array of TDADataTable; aSQLs: array of string)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSQLs: A DA SQL query strings.

FillWithDASql (array of TDADataTable, array of string, array of DataParameterArray)  overload    (declared in TDABaseDataAdapter)

The method fills given data tables with the data from the server with a glance of SQL strings using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTables: array of TDADataTable; aSQLs: array of string; aParameters: array of DataParameterArray)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSQLs: A DA SQL query strings.
  • aParameters: The specified collection of parameters

FillWithDASql (TDADataTable, string, DataParameterArray)  overload    (declared in TDABaseDataAdapter)

The method fills given data table with the data from the server with a glance of SQL string using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTable: TDADataTable; aSQL: string; aParameters: DataParameterArray)

Parameters:

  • aTable: Data table that should receive the data from the server.
  • aSQL: A DA SQL query string.
  • aParameters: Parameters

FireAfterApplyUpdates  protected    (declared in TDABaseDataAdapter)

procedure FireAfterApplyUpdates(aTables: TDADataTableList)

Parameters:

  • aTables:

FireBeforeApplyUpdates  protected    (declared in TDABaseDataAdapter)

procedure FireBeforeApplyUpdates(aTables: TDADataTableList)

Parameters:

  • aTables:

FlushSchema    (declared in TDABaseDataAdapter)

Deletes schema

procedure FlushSchema

Get_GetDataCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to fetch data from the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_GetDataCall: TDARemoteRequest

Get_GetSchemaCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to obtain schema information from the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_GetSchemaCall: TDARemoteRequest

Get_GetScriptsCall  protected virtual    (declared in TDACustomDataAdapter)

Gets access to the server call that will be used to download business rules scripts.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable

function Get_GetScriptsCall: TDARemoteRequest

Get_UpdateDataCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to apply changes back to the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_UpdateDataCall: TDARemoteRequest

GetLinkedTables    (declared in TDACustomDataAdapter)

Returns list of datatables that use given DataAdapter

function GetLinkedTables: TList<TComponent>

GetTableNamesAsCommaText  protected    (declared in TDABaseDataAdapter)

Produces comma-separated list of table names

function GetTableNamesAsCommaText(aTableArray: array of TDADataTable): ROUTF8String

Parameters:

  • aTableArray: source

OnAfterApplyUpdates    (declared in TDABaseDataAdapter)

Fires directly after the adapter has finished applying updates for a specific data table.

property OnAfterApplyUpdates: TDAApplyUpdatesEvent read write
delegate: procedure OnAfterApplyUpdates(Sender: TObject; aTable: TDADataTable; const Delta: IDADelta)

OnBeforeApplyUpdates    (declared in TDABaseDataAdapter)

Fires directly before the adapter starts applying updates for a specific data table.

property OnBeforeApplyUpdates: TDAApplyUpdatesEvent read write
delegate: procedure OnBeforeApplyUpdates(Sender: TObject; aTable: TDADataTable; const Delta: IDADelta)

OnBeforeProcessFailures    (declared in TDABaseDataAdapter)

Fires before the adapter starts processing failures

property OnBeforeProcessFailures: TDABeforeProcessFailuresEvent read write
delegate: procedure OnBeforeProcessFailures(Sender: TObject; aTablesList: TDADataTableList; aFailedDeltas: TDADeltaChangeList; var aFailureBehavior: TDAFailureBehavior)

OnGenerateRecordMessage    (declared in TDABaseDataAdapter)

Allows to customize default error message

property OnGenerateRecordMessage: TDAOnGenerateRecordMessage read write
delegate: procedure OnGenerateRecordMessage(Sender: TObject; aChange: TDADeltaChange; ADatatable: TDADataTable; var aMessage: string)

OnShowReconcileRecordInAppUI    (declared in TDABaseDataAdapter)

Fires before showing a ReconcileDialogDetails with detailed information about the selected error to the user. If handled, ReconcileDialogDetails will not be shown to the user.

property OnShowReconcileRecordInAppUI: TDAShowReconcileRecordInAppUIEvent read write
delegate: procedure OnShowReconcileRecordInAppUI(Sender: TObject; aChange: TDADeltaChange; aDatatable: TDADataTable; var aHandled: Boolean; var aAction: TDAReconcileDialogAction)

OnShowReconcleDialog    (declared in TDABaseDataAdapter)

Fires before showing a ReconcileDialogDetails with detailed information about the selected error to the user.

property OnShowReconcleDialog: TDAShowReconcleDialogEvent read write
delegate: procedure OnShowReconcleDialog(Sender: TObject; var AFailedDeltaList: TDADeltaChangeList; aTableList: TDADataTableList; var aHandled: boolean)

OnStreamerBeforeFieldValueSerialization

This event allows to change the value of a field before serialization.

property OnStreamerBeforeFieldValueSerialization: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerBeforeFieldValueSerialization(const aField: TDAField; var Value: Variant)

OnStreamerReadDatasetProgress

This event allows to visualize the progress of reading the dataset.

property OnStreamerReadDatasetProgress: TDALDADataStreamerReadDatasetProgress read write
delegate: procedure OnStreamerReadDatasetProgress(Sender: TDALocalDataAdapter; const aDataset: IDADataset; const aCurrent: Integer; const aTotal: Integer)

OnStreamerReadFieldValue

This event allows to change the value of a field after reading.

property OnStreamerReadFieldValue: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerReadFieldValue(const aField: TDAField; var Value: Variant)

OnStreamerWriteDataset

This event is called before a dataset is serialized.

property OnStreamerWriteDataset: TDALDADatasetOperation read write
delegate: procedure OnStreamerWriteDataset(DataStreamer: TDALocalDataAdapter; const Datasetname: string; const Dataset: IDADataset)

OnStreamerWriteDatasetProgress

This event allows to visualize the progress of writing the dataset.

property OnStreamerWriteDatasetProgress: TDALDADataStreamerWriteDatasetProgress read write
delegate: procedure OnStreamerWriteDatasetProgress(Sender: TDALocalDataAdapter; const aDataset: IDADataset; const aCurrent: Integer; const aMaxRecords: Integer)

OnStreamerWriteFieldValue

This event allows to change the value of a field before serialization.

property OnStreamerWriteFieldValue: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerWriteFieldValue(const aField: TDAField; var Value: Variant)

OnStreamerWriteFieldValueEx

This event allows to change the value of a field before serialization.

property OnStreamerWriteFieldValueEx: TDAReadWriteFieldValueEx read write
delegate: procedure OnStreamerWriteFieldValueEx(const aDataset: IDADataset; const aField: TDAField; var Value: Variant)

ReadSchema    (declared in TDABaseDataAdapter)

Downloads the Schema from the Data Abstract server .

function ReadSchema(aForceReRead: boolean): TDAClientSchema

Parameters:

  • aForceReRead: Flag indicating whether Schema should be downloaded even if the Schema is already cached in the Schema property

ReconcileProvider    (declared in TDABaseDataAdapter)

Reconcile Dialog provider.

property ReconcileProvider: TDABaseReconcileProvider read write

ROFreeNotification    (declared in TROComponent)

Forwards notification messages to all owned RO components.

procedure ROFreeNotification(AComponent: TComponent)

Parameters:

  • AComponent: component

RORemoveFreeNotification    (declared in TROComponent)

Disables destruction notification for specified RO component.

procedure RORemoveFreeNotification(AComponent: TComponent)

Parameters:

  • AComponent: component

Schema    (declared in TDABaseDataAdapter)

Server's schema.

property Schema:

ServiceInstance

The service instance currently in use. When the ServiceName is set, this property will be initialized when the first call is done. It is also possible to assign your own instance.

property ServiceInstance: IDataAbstractLocalServiceAccess read write

ServiceName

Name of the local service that holds the schema and business logic.

property ServiceName: string read write

SessionID

The client ID that the service will get while running.

property SessionID: TGuid read write

UpdateData  protected override

Applies changes back to the server

procedure UpdateData(aDeltaList: IDeltaArray)

Parameters:

  • aDeltaList: Delta list.

 

AutoFillScripts    (declared in TDABaseDataAdapter)

Autofills business rules scripts at opening tables

property AutoFillScripts: Boolean read write

CacheSchema  protected    (declared in TDABaseDataAdapter)

Toggles whether the data adapter will maintain a local cache of the schema retrieved from the server with subsequent calls to the Schema property. If set to true, the adapter will download the schema the first time the Schema property is accessed, and subsequent accesses will return the same schema instance. If set to false (default), the schema will be re-downloaded from the server every time. You can flush any cached schema by setting this property to false and then immediately back to true, or by calling the FlushSchema method. Set this property to false when you expect frequent changes in the schema information, or when you want to update data tables to a changed server, at design time. Set it to true you want your application to only obtain the schema once and don't expect the server-side schema to change while the application is running.

property CacheSchema: boolean read write

DataStreamer  protected    (declared in TDACustomDataAdapter)

Defines the type of data streamer to be used for reading and writing data from and to the network. The type of streamer assigned here must match the streamer used on the ServiceDataStreamer property of the sever in the descendant classes.

property DataStreamer: TDADataStreamer read write

DynamicSelect    (declared in TDABaseDataAdapter)

Flag indicating whether Data Adapter should perform queries using the Dynamic Select feature.

property DynamicSelect: Boolean read write

FailureBehavior    (declared in TDABaseDataAdapter)

Manages how TDABaseRemoteDataAdapter behaves when an error is encountered.

property FailureBehavior: TDAFailureBehavior read write

ReconcileProvider    (declared in TDABaseDataAdapter)

Reconcile Dialog provider.

property ReconcileProvider: TDABaseReconcileProvider read write

Schema    (declared in TDABaseDataAdapter)

Server's schema.

property Schema:

ServiceInstance

The service instance currently in use. When the ServiceName is set, this property will be initialized when the first call is done. It is also possible to assign your own instance.

property ServiceInstance: IDataAbstractLocalServiceAccess read write

ServiceName

Name of the local service that holds the schema and business logic.

property ServiceName: string read write

SessionID

The client ID that the service will get while running.

property SessionID: TGuid read write

 

constructor Create (IDataAbstractLocalServiceAccess)  reintroduce overload beta

Creates a new instance and initializes the ServiceInstance property.

constructor Create(const aServiceInstance: IDataAbstractLocalServiceAccess)

Parameters:

  • aServiceInstance: Data Service instance that will be used to execute the TDALocalDataAdapter methods

constructor Create (string)  reintroduce overload beta

Creates a new instance and initializes the ServiceName property.

constructor Create(const aServiceName: string)

Parameters:

  • aServiceName: Name of the Data Service that will be used to execute the TDALocalDataAdapter methods

constructor Create (TComponent)  override    (declared in TDABaseDataAdapter)

Creates a new instance.

constructor Create(aOwner: TComponent)

Parameters:

  • aOwner: Owner.

ApplyUpdates  override    (declared in TDABaseDataAdapter)

Applies local updates, which are represented in the collection of data tables, back to the server and returns true if the updates were successfully applied on the server. Otherwise returns false.

function ApplyUpdates(aTables: array of TDADataTable; aRefetchAll: boolean): boolean

Parameters:

  • aTables: Input collection of data tables with updates that should be applied on the server.
  • aRefetchAll: True: the data tables reopen after applying updates on the server. False: they don't reopen. By default, this parameter equals False.

Assign  override    (declared in TDABaseDataAdapter)

Copies the contents of another, similar object.

procedure Assign(Source: TPersistent)

Parameters:

  • Source: Instance whose properties will be copied

CheckProperties  override    (declared in TDABaseDataAdapter)

Validates the data adapter properties.

procedure CheckProperties(ACheckOnlyDataStreamer: Boolean)

Parameters:

  • ACheckOnlyDataStreamer: True if only the data streamer should be checked, otherwise False. By default, this parameter equals False.

CreateTableRequestInfo  protected    (declared in TDABaseDataAdapter)

Generates TableRequestInfo based on given parameters.

function CreateTableRequestInfo(aTable: TDADataTable; aIncludeSchema: boolean; aDynamicWhereExpression: TDAWhereExpression): TableRequestInfo

Parameters:

  • aTable: datatable
  • aIncludeSchema: include schema
  • aDynamicWhereExpression: dynamic where expression

Fill (array of TDADataTable, array of TableRequestInfo, boolean, boolean, Boolean)  overload    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aTableRequestInfoArray: array of TableRequestInfo; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aTableRequestInfoArray: The specified collection of TableRequestInfo that contains additional parameters.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

Fill (array of TDADataTable, array of TDAWhereExpression, boolean, boolean, Boolean)  overload    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aWhereClauses: array of TDAWhereExpression; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aWhereClauses: The specified collection of where clasuses that should receive the data from the server.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

Fill (array of TDADataTable, boolean, boolean, Boolean)  overload override    (declared in TDABaseDataAdapter)

Retrieves data from the server for all of the specified TDADataTables. In most scenarios you will not call this method yourself, but simply open the respective data table, causing data to be retrieved automatically. However, calling Fill yourself provides additional flexibility, including the option to fill multiple data tables at the same time, avoiding unnecessary server round-trips.

procedure Fill(aTables: array of TDADataTable; aSaveCursor: boolean; aIncludeSchema: boolean; aAppendMode: Boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSaveCursor: Defines whether the cursors that are related with the collection of data tables should be saved (true) or not (false).
  • aIncludeSchema: Defines whether the schema should be included while creating table request information (true) or not (false).
  • aAppendMode: Defines whether the AppendMode in the related TDATableOptionsArray collection should be set (true) or not (false). By default, this parameter equals false.

FillSchema  override    (declared in TDABaseDataAdapter)

Retrieves schema information for all specified TDADataTables, and configures their Fields and Params setup to match the schema from the server. You can perform the same task at design-time for individual data tables by right-clicking the data table component and selecting "Retrieve DataTable Schema" from the context menu.

procedure FillSchema(aTables: array of TDADataTable; aPreserveLookupFields: boolean; aPreserveClientCalcFields: boolean)

Parameters:

  • aTables: The specified collection of data tables that should receive the schema information.
  • aPreserveLookupFields: Defines whether the collection of lookup fields should be preserved (true) or not (false). By default, this parameter equals false
  • aPreserveClientCalcFields: Defines whether the collection of calculated fields should be reserved (true) or not (false). By default, this parameter equals false

FillScripts  override    (declared in TDABaseDataAdapter)

Retrieves business rules scripts for all specified TDADataTables from the server.

procedure FillScripts(aTables: array of TDADataTable)

Parameters:


FillWithDASql (array of TDADataTable, array of string)  overload    (declared in TDABaseDataAdapter)

The method fills given data tables with the data from the server with a glance of SQL strings using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTables: array of TDADataTable; aSQLs: array of string)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSQLs: A DA SQL query strings.

FillWithDASql (array of TDADataTable, array of string, array of DataParameterArray)  overload    (declared in TDABaseDataAdapter)

The method fills given data tables with the data from the server with a glance of SQL strings using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTables: array of TDADataTable; aSQLs: array of string; aParameters: array of DataParameterArray)

Parameters:

  • aTables: The specified collection of data tables that should receive the data from the server.
  • aSQLs: A DA SQL query strings.
  • aParameters: The specified collection of parameters

FillWithDASql (TDADataTable, string, DataParameterArray)  overload    (declared in TDABaseDataAdapter)

The method fills given data table with the data from the server with a glance of SQL string using TableRequestInfoV6 with DA SQL under the hood.

Note: works only with .NET servers

procedure FillWithDASql(aTable: TDADataTable; aSQL: string; aParameters: DataParameterArray)

Parameters:

  • aTable: Data table that should receive the data from the server.
  • aSQL: A DA SQL query string.
  • aParameters: Parameters

FireAfterApplyUpdates  protected    (declared in TDABaseDataAdapter)

procedure FireAfterApplyUpdates(aTables: TDADataTableList)

Parameters:

  • aTables:

FireBeforeApplyUpdates  protected    (declared in TDABaseDataAdapter)

procedure FireBeforeApplyUpdates(aTables: TDADataTableList)

Parameters:

  • aTables:

FlushSchema    (declared in TDABaseDataAdapter)

Deletes schema

procedure FlushSchema

Get_GetDataCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to fetch data from the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_GetDataCall: TDARemoteRequest

Get_GetSchemaCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to obtain schema information from the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_GetSchemaCall: TDARemoteRequest

Get_GetScriptsCall  protected virtual    (declared in TDACustomDataAdapter)

Gets access to the server call that will be used to download business rules scripts.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable

function Get_GetScriptsCall: TDARemoteRequest

Get_UpdateDataCall  protected virtual    (declared in TDACustomDataAdapter)

Describes the server call that will be used to apply changes back to the server.
This function is only used for backward compatibility to provide access to this function in the legacy events in the TDADataTable.

function Get_UpdateDataCall: TDARemoteRequest

GetLinkedTables    (declared in TDACustomDataAdapter)

Returns list of datatables that use given DataAdapter

function GetLinkedTables: TList<TComponent>

GetTableNamesAsCommaText  protected    (declared in TDABaseDataAdapter)

Produces comma-separated list of table names

function GetTableNamesAsCommaText(aTableArray: array of TDADataTable): ROUTF8String

Parameters:

  • aTableArray: source

ReadSchema    (declared in TDABaseDataAdapter)

Downloads the Schema from the Data Abstract server .

function ReadSchema(aForceReRead: boolean): TDAClientSchema

Parameters:

  • aForceReRead: Flag indicating whether Schema should be downloaded even if the Schema is already cached in the Schema property

ROFreeNotification    (declared in TROComponent)

Forwards notification messages to all owned RO components.

procedure ROFreeNotification(AComponent: TComponent)

Parameters:

  • AComponent: component

RORemoveFreeNotification    (declared in TROComponent)

Disables destruction notification for specified RO component.

procedure RORemoveFreeNotification(AComponent: TComponent)

Parameters:

  • AComponent: component

UpdateData  protected override

Applies changes back to the server

procedure UpdateData(aDeltaList: IDeltaArray)

Parameters:

  • aDeltaList: Delta list.

 

OnAfterApplyUpdates    (declared in TDABaseDataAdapter)

Fires directly after the adapter has finished applying updates for a specific data table.

property OnAfterApplyUpdates: TDAApplyUpdatesEvent read write
delegate: procedure OnAfterApplyUpdates(Sender: TObject; aTable: TDADataTable; const Delta: IDADelta)

OnBeforeApplyUpdates    (declared in TDABaseDataAdapter)

Fires directly before the adapter starts applying updates for a specific data table.

property OnBeforeApplyUpdates: TDAApplyUpdatesEvent read write
delegate: procedure OnBeforeApplyUpdates(Sender: TObject; aTable: TDADataTable; const Delta: IDADelta)

OnBeforeProcessFailures    (declared in TDABaseDataAdapter)

Fires before the adapter starts processing failures

property OnBeforeProcessFailures: TDABeforeProcessFailuresEvent read write
delegate: procedure OnBeforeProcessFailures(Sender: TObject; aTablesList: TDADataTableList; aFailedDeltas: TDADeltaChangeList; var aFailureBehavior: TDAFailureBehavior)

OnGenerateRecordMessage    (declared in TDABaseDataAdapter)

Allows to customize default error message

property OnGenerateRecordMessage: TDAOnGenerateRecordMessage read write
delegate: procedure OnGenerateRecordMessage(Sender: TObject; aChange: TDADeltaChange; ADatatable: TDADataTable; var aMessage: string)

OnShowReconcileRecordInAppUI    (declared in TDABaseDataAdapter)

Fires before showing a ReconcileDialogDetails with detailed information about the selected error to the user. If handled, ReconcileDialogDetails will not be shown to the user.

property OnShowReconcileRecordInAppUI: TDAShowReconcileRecordInAppUIEvent read write
delegate: procedure OnShowReconcileRecordInAppUI(Sender: TObject; aChange: TDADeltaChange; aDatatable: TDADataTable; var aHandled: Boolean; var aAction: TDAReconcileDialogAction)

OnShowReconcleDialog    (declared in TDABaseDataAdapter)

Fires before showing a ReconcileDialogDetails with detailed information about the selected error to the user.

property OnShowReconcleDialog: TDAShowReconcleDialogEvent read write
delegate: procedure OnShowReconcleDialog(Sender: TObject; var AFailedDeltaList: TDADeltaChangeList; aTableList: TDADataTableList; var aHandled: boolean)

OnStreamerBeforeFieldValueSerialization

This event allows to change the value of a field before serialization.

property OnStreamerBeforeFieldValueSerialization: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerBeforeFieldValueSerialization(const aField: TDAField; var Value: Variant)

OnStreamerReadDatasetProgress

This event allows to visualize the progress of reading the dataset.

property OnStreamerReadDatasetProgress: TDALDADataStreamerReadDatasetProgress read write
delegate: procedure OnStreamerReadDatasetProgress(Sender: TDALocalDataAdapter; const aDataset: IDADataset; const aCurrent: Integer; const aTotal: Integer)

OnStreamerReadFieldValue

This event allows to change the value of a field after reading.

property OnStreamerReadFieldValue: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerReadFieldValue(const aField: TDAField; var Value: Variant)

OnStreamerWriteDataset

This event is called before a dataset is serialized.

property OnStreamerWriteDataset: TDALDADatasetOperation read write
delegate: procedure OnStreamerWriteDataset(DataStreamer: TDALocalDataAdapter; const Datasetname: string; const Dataset: IDADataset)

OnStreamerWriteDatasetProgress

This event allows to visualize the progress of writing the dataset.

property OnStreamerWriteDatasetProgress: TDALDADataStreamerWriteDatasetProgress read write
delegate: procedure OnStreamerWriteDatasetProgress(Sender: TDALocalDataAdapter; const aDataset: IDADataset; const aCurrent: Integer; const aMaxRecords: Integer)

OnStreamerWriteFieldValue

This event allows to change the value of a field before serialization.

property OnStreamerWriteFieldValue: TDAReadWriteFieldValue read write
delegate: procedure OnStreamerWriteFieldValue(const aField: TDAField; var Value: Variant)

OnStreamerWriteFieldValueEx

This event allows to change the value of a field before serialization.

property OnStreamerWriteFieldValueEx: TDAReadWriteFieldValueEx read write
delegate: procedure OnStreamerWriteFieldValueEx(const aDataset: IDADataset; const aField: TDAField; var Value: Variant)

See Also