Add a DB Query action

To add or manage database records, you can add a DB query action for a form or form controls such as drop-down lists or text boxes.

Use the DB Query action to point to the required database and design access for operations such as View, Add, Update and Delete. For example, you can interact with the Customer table in a database to display the customer name in the Name box on a Customer Details form.

You can use the DB Query action to add multiple records at a time, search for records with similar values, and use stored procedures.

TotalAgility is integrated with Data Access Service (DAS) that allows you to easily connect and interact with a selected relational database.

Note the following:

  • You can use DAS to connect to any database for which an OLE DB driver is available. However, the Data Access Service in TotalAgility only supports SQL Server and Oracle databases.

  • Before you can create a DB Query action, you must set up a database connection string. See Set up a database connection string.

Additional Information

The following values are provided:

  • All numeric types = -1

  • Dates = 01/01/1900

  • Byte = 0

  • String = Blank String

  • Boolean = False

  1. On the Form Modeling bar, click Actions.
  2. On the Actions page, click Add Generic Add.
  3. On the Type list, select DB Query.
  4. Enter a Name and Description for the action.
  5. Optionally, configure a unique action for each language separately. See Configure multilingual actions for a form or control for more information.
  6. To create a DB Query, in the Connection String box, consume or enter the database connection string, and click Configure. See Create a DB query.

    Once a query is created, it appears in the Query box.

    Note
  7. Map the output parameters using dynamic or static values.
  8. Click OK.

    The newly created action is added to the table.

  9. Click Save.
  10. Associate the action with the control to trigger this action. To call the DB Query action upon form load, associate the action with the form. See Associate an action with a form or control.

    When this action is triggered, the relevant action is performed based on the DB query.