Relationships

Advanced Job: Discover primary and foreign key relationships auto

This job is used to discover all the Primary and Foreign Keys using the formula

'Row Count of a table = Distinct count of a table column.'

To discover the Primary and Foreign Keys, the advanced job first verifies the Row count of the Table, and then the unique values are identified and computed.

On the data column table column summary, you can view the primary key and foreign key information.

How to Run the Job:

  1. In the OvalEdge application, navigate to the Administration > Advanced Jobs module, and the list of Advanced Jobs in the OvalEdge application is displayed.
  2. In the Name column field, enter the “Discover Primary and Foreign key recommendations auto” Advanced Job name and click enter, and related advanced jobs are displayed.
    AdvJobEntity5
  3. Click on the edit icon available in the Attribute column field. The Edit Advance Job pop-up window is displayed.
    AdvJobEntity6
  4. Enter the details of the parameters mentioned in the Input section and click on the Update button.
    Input
    Connector ID/Name, Schema ID/Name, and Build Relationship Across Schema(True/False).
    Note: Multiple can be given with comma(,) separated.
    If Build Relationship Across Schema is: By default, it is considered false. 
    1. TRUE: This job will build relationships across the schema.
    2. False: This job will not build relationships across the schema and If you keep the field empty by default the system will consider it as false.
    Note:
    1. If schema IDs are provided as input, this relationship job fetches all primary key columns under the given schema tables where the respective table row count is greater than 100 and the column distinct count is equal to the table row count.
    2. If schema IDs are not provided as input, then this relationships job fetches all primary key columns under the available connections on the connected database where the respective table row count is greater than 100 and the column distinct count is equal to the table row count.
    3. Now taking these primary columns as base, for each primary key column we compare the top 50 values of other columns, if any one top value is matched then we build relationships between those two columns.
      Conditions
      1. Schemas must be profiled before running this job.
      2. Only the columns of tables having row_count > 100 and table row count = column distinct count are considered primary key columns.
    4. The difference identified between 'Discover Relationships Automatically' and 'Discover Primary and Foreign key relationships auto' jobs is that the schemas must be profiled before running 'Project Level Relationships Building'. Both these jobs work on Top value comparison of columns.
  5. Select the check box for the advanced job, click on the Run Advanced Job button, and a confirmation message to run the advanced job is displayed. 
    Note: The Run Advance Job button is only enabled if the Advanced Job checkbox is selected.
  6. Click on the Submit button, and a prompt message is displayed accordingly, whether the Job is Successful, Error, or Partial Success.
  7. Navigate to the Jobs module to view the logs. Once the job is successful, the Job Step Status is displayed as Success and the system starts calculating scores after building all relationships.

      Copyright © 2023, OvalEdge LLC, Peachtree Corners GA USA