Posted: 5 May 2016 17:40 EDT Last activity: 6 May 2016 12:19 EDT
How to generate a unique id for an external table
I have a data class in Pega for which there is an external table in Pega DB. Every time a record is inserted into the table, I need to have a unique id for the record. Can anyone tell me how to accomplish this requirement?
There is OOTB GenerateID activity which looks for the highest ID in the table and fetches the ID for the work objects, but I have to embed this logic in file processing. After parsing each record in the file I need to insert the same data into a table and there will be millions of records. So using an activity with Java step might impact the performance
Have the pxObjClass,pzinskey,pxCreateDateTime defined as the columns in the DB table. Have the pzInsKey as the primary key of the table. When you do an Obj-Save to save the data instance pzInskey is auto generated and saved in the table.