Our application has a class XXX-Data-DWH-List_Product which is mapped to a table pr_List_Product in db.
I have added new key[Name] to this class XXX-Data-DWH-List_Product when i do test connectvity i see this error
There is a key mismatch: the keys defined for class XXX-Data-DWH-List_Product do not match the primary key columns for external data table customerdata.pr_pr_List_Product in database CustomerData; the class keys are [ID,Type,Name], but the table's primary keys are [customerdata.type, customerdata.id]
I have tired to update the key as below :
Configure---Data model--Data base table mapping
Select Category : Data-
Class :XXX-Data-DWH-List_Product Data base : Customer Data Edit and select the new keys and save.
@Vikram22 if you have write-access to DB, you can do it using ALTER statement. Or, in postgresql for example, you can use pgadmin to create a new constraint with the list of columns you want to have as a key
Posted: 1 year ago
Posted: 27 Aug 2021 10:00 EDT
Basil (Vasilii) Pozdeev (vaspoz)
Senior System Architect
@Vikram22 and if you don't have access to DB then I looks like it's not possible to do it only from Pega (weeeeeell, unless you create a custom SQL connector with ALTER statement. But that's a dirty trick)