Question

3
Replies
5112
Views
Robin Markose (markr1)
PEGA
Principal Solutions Engineer
Pegasystems Inc.
IN
markr1 Member since 2014 2 posts
PEGA
Posted: September 27, 2016
Last activity: June 18, 2017
Posted: 27 Sep 2016 4:31 EDT
Last activity: 18 Jun 2017 11:15 EDT
Closed

What are the best practices for fetching and updating records in external database tables from PRPC

We have a scenario where the PRPC should point to the external Database and create necessary data classes in PRPC. The external DB contains the foreign key relations as mentioned below and the corresponding Data Classes in PRPC.







Consider a one – to – one relation from CFSDPolicy to CFSClaim table.


With this Data Model structure, what are the best practices for fetching and updating the records.



What we have done:


  1. To Fetch a CFSPolicy Record with CFSClaim data..
    1. Created a Report Definition in CFSPolicy data class and used joins in Data access tab of RD to connect to CFSClaim data class.

We have a scenario where the PRPC should point to the external Database and create necessary data classes in PRPC. The external DB contains the foreign key relations as mentioned below and the corresponding Data Classes in PRPC.

Consider a one – to – one relation from CFSDPolicy to CFSClaim table.

With this Data Model structure, what are the best practices for fetching and updating the records.

What we have done:

  1. To Fetch a CFSPolicy Record with CFSClaim data..
    1. Created a Report Definition in CFSPolicy data class and used joins in Data access tab of RD to connect to CFSClaim data class.

    2. Created an activity which loads the Report Definition and merges the CFSClaim from pxPages of pxResults into “CFSPolicy.CFSClaim”.
  2. To update a CFSPolicy record and the corresponding CFSClaim record..
    1. Separated CFSClaim from CFSPolicy Object.

    2. In the activity step, called “Save” on CFSPolicy
    3. Removed pxSubscript from CFSClaim object
    4. In the activity step, called “Save” on CFSClaim

If this was in pr_other table, we can treat the CFSPolicy and CFSClaim as one unit as CFSPolicy contains CFSClaim. Fetching or saving CFSPolicy will fetch or save CFSClaim record also. But when it is external tables , then we have to treat CFSPolicy and CFClaim as different.

For more info, please refer the attached doc..

***Updated by moderator: Lochan to add Categories***

Data Integration Reporting
Moderation Team has archived post, This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.