Question
Tech Mahindra
CA
Last activity: 13 Dec 2016 19:55 EST
How to archive Work Object Table data to another table in the same database
Hi All,
Is there anyway to archive the work objects(and the related data) to another table in the same database. Of course we have the Purge/Archive wizard, but this cann't help us in copying the data to another table.
Please let me know the better approach to do this.
Thanks in advance
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Updated: 13 Dec 2016 1:36 EST
Tech Mahindra
CA
Finally we are going with the below approach
1) Created a new schema in and craeted the tables to be archived in the new schema
2) Created Stored Procedures to insert the archived data from PEGA_DATA schema tables(pc_work, pc_data_workattach etc.)
Areteans
IN
Hi Sundeep,
Can you please refer below post which is talking about of similar kind of requirement,
Thanks,
Bala
Tech Mahindra
CA
Hi Bala,
Thank you for responding...
We are plaaning to archive the WO data from WO table and related tables(which is prior to an year) to another table and show the archived data in other table to the user.
Example: WOs in "pc_work" to "pc_work_archive"
For this we are looking for the best approach..
Areteans
IN
HI Sundeep,
- create a clone table of pc_work (we could manually run the sql scripts)
- update Data-Admin-DB-Table instance for the work class with this cloned table.
Please share your thoughts/observations, Thank you!
Capgemini
IN
You can not archive the WO in the same application with same DB, as there are lots of tables that got affected by archiving and purging. You need another envirnment to store the archived WOs. Or you can write custom activity to store the table data to different table(By connect sql). In that case you need to know which are the tables affected by your WO. Work table, history table, Attachment table, index table to name a few.
-Saikat
Accepted Solution
Updated: 13 Dec 2016 1:36 EST
Tech Mahindra
CA
Finally we are going with the below approach
1) Created a new schema in and craeted the tables to be archived in the new schema
2) Created Stored Procedures to insert the archived data from PEGA_DATA schema tables(pc_work, pc_data_workattach etc.)
Capgemini
IN
This should be working but the only catch is if you expose a new property in work table, you need to update the same in the duplicate table and update the proc to set the value as well. But you will have blob which will contain the value though.
IKOR
AU
Hi Sundeep,
How are you handling the Search functionality in the application ? If i would like to search the work object which is older than one year , then where should the search query to look for the data ? Is it active transactional database or archive database ?
Cheers,
Naren