Posted: 21 Apr 2017 6:32 EDT Last activity: 17 May 2017 8:19 EDT
Pega limitation of not allowing property with same name but different case - can we use property qualifier to overcome this?
I am parsing a json string (coming from a DB) in Pega 7 using the standard API adoptJSONObject(). One of the elements in the json string is "name". Since the property "Name" already exists in @baseclass, it doesn't allow me to create a property called "name" in any class throwing an error "" . I am trying to understand which of the 3 below solutions would be best suited for this problem?
Option 1: Can I use property qualifier to over come this? If so then what should be the qualifier to use? Tried pzExternalName but it did not work (It does work for json coming from REST services but not when I get it from the DB)
Option 2: Can I temporarily disable Pega's OOTB validation while saving the rule so that I am able to create the property "name"
Option 3: Revert back to our pre-Pega 7 java function where I have flexibility to map a json element to a prop with diff name (or with different case)
Pega version is 7.1.9. The Option 1 did not work. So we went ahead & replaced all the name elements in the json response with Name before parsing it using out Pega 7 API adoptJSONObject(). THis did the trick.