Some customers want to control the number of child rows being brought in from Subset. The main purpose of this is to limit the Subset size by the driving table and by the child tables that might have large numbers of transactions. This is possible and you can restrict non-driving rows from GTSubset.
Can users restrict non-driving rows in Subset?
- CA Test Data Manager (TDM)- Subset
- Product release versions 3.6 and above.
- The “rownum < x” approach that is suggested below is only supported on Oracle.
Yes, you can restrict non-driving rows from GTSubset by adding SQL to a table relationship. See the below example:
- In Subset, in the left-hand pane, click on the table that you would like to add the SQL relationship rule to.
- Choose the 'Edit Link' option from the list.
- In the 'Edit Link' window, click on the 'Columns' tab.
- Select the columns which you would like to add a rule to. In this screenshot example, you can see that the 'PERSON_ID' (PK) and 'ORDER_ID' (PK) have been chosen.
- Click on the 'SQL' tab to add a condition to. If the SQL added references other tables, for example one or more in statements, the SQL objects should be fully qualified. For example, TRAVEL.CUSTOMER.CUSTOMER_ID and NO alias names used. The SQL will look like the screenshot below: The “rownum < x” approach that is suggested is only supported on Oracle. You can add similar clauses to restrict the number of records on other Database platforms.
- Add a 'Rule Description' name if you would like.
- Click the 'OK' button.
- You will receive a 'Changes Saved' message. Click the 'OK' button.
- If you experience any issues, please open a support case on https://support.ca.com/irj/portal/newhome or call 1-800-225-5224.
- For more documentation on Subset, please review our online documentation: https://docops.ca.com/ca-test-data-manager/3-6/en/provisioning-test-data/subset-production-data