Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Layout Builder helps you to upload You can create an Advanced Database Layout using Layout Builder in Adeptia Connect. Layout Builder helps you create an Advanced Database Layout by importing a JSON (downloaded from Advanced Database Layout manage page) file to define the layoutor by using a database table. By default, this feature Layout Builder remains disabled in the product . You – you need to enable the Layout Builder feature before to enable it before you can create an Advanced Database Layout. a layout.

Steps to create Advanced Database Layout:

  1. Click Configure > LAYOUTS > Advanced Database.
  2. Click Create Advanced Database Layout.
  3. On the Create Layout screen, select the Layout Builder option from the drop-down list of  option in the Select Layout UI Type field.


     
  4. Click Next. The Create New Advanced Database screen is displayed.


  5. Type the name and description of the new layout activity in the Name and Description

     text boxes

     fields.

    Info

    Name: Only alphanumeric and underscore are allowed and you must start the layout name with an alphabet or underscore.
    Description: Only alphanumeric and few special characters (_ - . : , @ $ ? \\ and space) are allowed and you must start the description with an Alphabet/Underscore/Number.


  6. Select the definition mode for the Advanced Database Layout. You can define the layout in the following ways: 
    • Import Definition file
    • Use Database Table

    Using Import Definition File

    1. Select Import Definition File.
    2. Select JSON in the Definition File field.
    3. Browse and upload the JSON file in the Upload Data File field.

    4. Select the project from the Project field.
    5. Click Continue.

    Using Use Database Table

    1. Select Use Database Table.
    2. Select the database info activity from the Database Info field. You can also edit the database info by clicking Image Added button.
    3. Select the project from the Project field.
    4. Click Continue.

    5. Anchor

      On the

      Database Schema
      Database Schema
      On the Record Definition

      page

       page, in the Database

      Schema

      Schema field, select a database

      Schema

      layout to create the first record.

      Info
      When you select the Database Schema, all the database tables associated with the selected schema are populated in the Database Table field.


    6. Select  the required database table from the Database

      Table

      Table field. Based on the selected Database Table, Column Details

      will

       will be displayed.

    7. In

      the

      the Column Details, select the column(s) that you want to include in Select query statement.

      Info

      You can also select

      the 

      the Primary Key

       checkbox to include column(s) in Select query

      checkbox if you want the field to be the Primary Key. Primary Key is the field on the basis of which the layout updates the target database table. You can use Primary Key only when you are using database layout activity as target database.

      As you select a column, the Select query statement is automatically defined in the Query Editor field. You can also manually define an altogether new or update an existing Select query statement in this field.

      You

      You can edit the query and add

      the

      the where clause with dynamic parameters as shown in the screenshot below. For all the added dynamic parameters a new field

      called

      called Placeholders is added to the screen – here you can enter the values for the dynamic parameters

      that are used for generating the XSD for this layout

      .

      image2022-6-6_0-13-19.pngImage Removed


      Image Added

    8. Click Save to add this record.

    The Record Definition page displays the details of created records and Records Hierarchy.

    Screenshot


    Image Added

    Info
    1. On Record Definition screen, you can
      Click
        1. Click Image Modified
      to
        1.  to edit a record.
      Click
        1. Click Image Modified
      to
        1.  to remove a record.
      1. The database table you selected in the previous step gets listed under
      the
      1. the Records Hierarchy panel. You can also click Image Modified to add a root table.
        image2022-6-6_0-15-20.pngImage Modified
        You can select a table under
      the
      1. the Record Hierarchy
      panel
      1.  panel and
      click Image Removed to add
      1. ,
        1. Click Image Added to add a child table to it.
        2. Click Image Added to view the data in the table.
      Image Removed
      1. Image Added


    2. In the Definition panel, 
      1. Expand the Advanced Properties.

      2. Define the Character-set encoding for your Database layout in the Character Set Encoding field. For example UTF-8.

      3. Select the Auto Increment increment Key Supportcheckbox, if you want to enable support of auto increment key in parent to be populated child as foreign key.

        Select the Schema Version checkbox

         checkbox if required. This feature is used when the parent table's Auto Increment column is referenced in the child table. Enabling this checkbox automatically populates the value in the child table's foreign key column with the Auto increment column's value from the parent table.

      4. Select schema version 2.0 checkbox if you want to create the layout without the name dependency.
      5. Select the Filter Invalid XML Characters checkbox to filter out invalid XML characters (if any) in the input data

        Info
        In case, the input data contains some characters that are invalid in XML, then this may result in the mapping getting aborted. 


      6. Select the Query Batch Update checkbox to enable the query batch update, and enter the batch size in the Query Batch Size field.

        Info

        Enabling the Query Batch Update checkbox leads to database updation in batches as per the positive value set in the QueryBatch Size field.
        For example, setting a value '10' in the Query Batch Size field will group 10 separate statements and submit them as a single batch. However setting the value to '0' will disable the batch execution and execution of every statement will occur simultaneously.

        You can achieve performance optimization by using batch update. The advantage of batch update is to reduce the network calls to the database by not executing every single SQL query when they are raised. By using this feature, you can send multiple queries to the database in a single instant and thereby reducing the number of JDBC calls and improving performance.

        This feature is available for the Insert and Update operation only.


      7. Select the Use Commit Count checkbox to enable the Commit Count field, and enter the number of statements that you want to commit to the database in a single instance in a field.

        Info

        When you set the commit count value to a positive integer value then the layout starts and commits a batch of transaction as per the number in the Commit Count text box. This helps in reducing the network traffic and in turn increases network performance. This is called as batch transaction.


      8. Select the Handle Null/Empty Element(s) checkbox to handle Null or Empty elements. 

      9. Select the Use Parent/Child DataSetcheckbox to. This field works in tandem with Commit Count.

        • If this checkbox and Commit Count is enabled then this will call commit when parent record (including its hierarchy) count is equal to commit count. In case of any error rollback will not happen
        • If this checkbox is enabled and Commit Count is disabled then this will call commit count for every
        record including
        • record including its hierarchy.
         In
        •  In case of any error in the
        record including
        • record including its hierarchy, the complete record will be rolled back.
        • If this checkbox is disabled and Commit Count is
        enabled  then
        • enabled  then this will call commit when count of its parent and its child
        record is
        • record is equal to commit count.
         In
        •  In case of any error rollback will not happen.

    3. Click Save Layout to save the Advanced Database Layout.

    Anchor
    Adding a Child table
    Adding a Child table
    Adding a Child table

    You can also add a child table to the parent table. To add a child table, follow the steps given below:

    Warning
    Before adding a child table, make sure you have defined a Primary Key inthe parent table.
    1. In the Record Hierarchy panel, select the parent table and click Image Added.
    2. Follow the instructions from step e to step g in the section Using Use Database Table. 

      Info
      You need to define a related key in the Related Key column in the column details to establish the relationship between the child and parent database table.


    3. Click Save.
      The child table is added to the Record Hierarchy panel.