search cancel

Gt Subset query not getting generated correct.

book

Article ID: 242883

calendar_today

Updated On:

Products

CA Test Data Manager (Data Finder / Grid Tools)

Issue/Introduction

    When we are generating the subset query for the targeted env., the query is not getting generated properly. we are attaching one script for reference, we have updated the targeted env. as UAT1 still in the script it is taking UAT19.

please find below the query we used for subset:

SELECT *
FROM [UAT1].[dbo].[table1]
where SUBSTRING    (Referencenumber,8,6)
in     (
SELECT ReferenceSequence
FROM [UAT1].[dbo].[table2]
where Productid < 2000000)
OR SUBSTRING    (Referencenumber,4,7)
in     (
SELECT ReferenceSequence
FROM [UAT1].[dbo].[table2]
where Productid > 1999999)

Also find below the part of the query, which is getting effected:

 " FROM [UAT19].[dbo].[trn_Risk] L0 WHERE (SUBSTRING   (Referencenumber,8,6) in    ( SELECT ReferenceSequence FROM [UAT19].[dbo].[temp_ProductRiskRandom] where Productid < 2000000) OR SUBSTRING   (Referencenumber,4,7) in    ( SELECT ReferenceSequence FROM [UAT19].[dbo].[temp_ProductRiskRandom] where Productid > 1999999))"

 

Cause

If the query extract is not saved to repository, we will get such issues.

Environment

Release : 4.9

Component : Subset

Resolution

Save the extract to either repository or file and then generate the script.

This issue happens only when the query is not saved to repository. Script generate uses the saved query.