Question
Cognizant
IN
Last activity: 5 Mar 2024 9:51 EST
How can we get the key of a data type
After adding a product rule how can we add a key for the data type that we want to deploy to test environment.
This is the key dbb2ea71-7c25-455f-8ee7-0ed43804e240 that my lead used to search for the exact key of the datatype.But I am not sure how to get this key in the first place.
***Edited by Moderator Rupashree to add Capability tags***
-
Reply
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Collabpartnerz
AU
Hi @TanyaS58
- If you want to select specific data instances, you can use the Query option under the Individual Instances to include section of product rule, to search for the data class (in your example "SA-ClientServices-Data-ReferenceDetails" ) and select individual data instances from the data instances displayed on the pop up. Pega will automatically recognize the keys of the selected instances and update the product rule form.
- If you want to include all the instances of the data class, you can simple use the Class Instances to Include option. Provide your class name under the Name column. (This will take include all the instances in your data class).
- If you are unable to do above, then you have to specify the pzInsKey of data instance in the Key column to include them in the product file. Key for a data instance can be found by opening the data instances using XML or querying the database using Query Runner.
After using any of the above option, its better to preview the product file and verify the rules include in the product to be sure if the product is only moving the desired rules.
Hope this helps.
Regards
Sundeep
Cognizant
IN
@Sudha Sundeep D ,i saw my lead doing the query runner option in the product (she also used the class SA-ClientServices-Data-ReferenceDetails to query)and then she selected a key but i want to know how can we understand that this is the required key that we want to include in the product rule.
As pzInskey value is completely different for the class as compared to the key being used in product, when i did view XML from actions tab of the class.
Collabpartnerz
AU
Hi @TanyaS58,
Query runner is nothing but an SQL client querying the pega database table. This is an option provided by Pega to directly check the records in any Pega table, instead of using another SQL client.
To find a key for any class instance (be it data/rule/work type) you can directly go to the Class Definition (right click on the class (SA-ClientServices-Data-ReferenceDetails) > Definition) and check the class properties mentioned/configured in the Keys section.
If that section has more than 1 property configured, then the primary key of that class instance is the combination of both the properties together.
Note: If the class is an abstract class, you will not find this Key section, as Abstract classes will not have instances.
Hope this helps.
Cognizant
IN
@Sudha Sundeep D hi the key configured is pyGUID,I wanted to know how to get this value dbb2ea71-7c25-455f-8ee7-0ed43804e240 via this pyGUID for that particular entry.
Pegasystems Inc.
CA
You can run a report pyGuid (on the concrete data class) to retrieve the values for each instance/record(attached screenshot for your reference).
NCS Pte. Ltd
SG
Hi @TanyaS58: You can find the key of the class by opening the class rule. This will give understanding of what is the property / column considered as keys. Please see this to know about pzinskey.
So when you need to include a row of a table in product, you need to include the pzinskey of that row in your product.
Thanks.
Updated: 5 Mar 2024 8:22 EST
Pegasystems Inc.
US
@TanyaS58 Normally, if we click the class name (next to the green leaf icon) in App Explorer, we can open an individual record and get its pzInskey. However, i've seen that instances in CustomerData db don't open the same way (probably don't have an ins handle?). In that cases, we used the Export/Import feature under Records tab of data type to move them to a higher environment.