Have an amazing solution built in RAD Studio? Let us know. Looking for discounts? Visit our Special Offers page!
CodeDelphiRAD Studio

Learn About How To Redirect Inserting, Deleting And Updating Records In Delphi With FireDAC

This sample shows how to redirect inserting, deleting and updating records using standalone table adapter.

Location

You can find the Commands sample project at:

  • Start | Programs | Embarcadero RAD Studio Sydney | Samples and then navigate to:
    • Object PascalDatabaseFireDACSamplesDApt LayerCommands
  • Subversion Repository:
    • You can find Delphi code samples in GitHub Repositories. Search by name into the samples repositories according to your RAD Studio version.

Files

File in DelphiContains
Commands.dproj
Commands.dpr
The project itself.
fCommands.pas
fCommands.fmx
The main form.

Implementation

The sample implements the following standalone table adapter features.

Create table adapter

Selecting data

Redirect records

Redirect all record inserts into FDQA_map2 table instead FDQA_map1:

Redirect all record deletes into FDQA_map3 table instead FDQA_map1:

Redirect all record updates into FDQA_map4 table instead FDQA_map1:

Add new rows

Post changes to RDBMS

For more details and links to other posts, you can refer to the link below:

http://docwiki.embarcadero.com/CodeExamples/Sydney/en/FireDAC.DAptLayerCommands_Sample

Check out the full source code for the demo over on GitHub or in your RAD Studio IDE examples section.


See What's New in 12.2 Athens See What's New in 12.2 Athens Dev Days of Summer 2-24

Reduce development time and get to market faster with RAD Studio, Delphi, or C++Builder.
Design. Code. Compile. Deploy.
Start Free Trial   Upgrade Today

   Free Delphi Community Edition   Free C++Builder Community Edition

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

IN THE ARTICLES