Persist Shared Record to secondary datasource

Topics related to the integration of LSPS with external systems.
Forum rules
Make sure every topic contains information about your LSPS version and if relevant also your server OS, client OS, database name and version, and application server name and version.
eric.graham
 
Posts: 53
Joined: Tue May 13, 2014 12:20 pm

Persist Shared Record to secondary datasource

Wed Mar 22, 2017 2:56 pm

Hello -
I have a need for a Shared Record to persist to a separate data source (defined in the openejb.xml connections), other than the LSPS_DS data source that is being used to connect the application. – I see “Schema:” field, but this does not seem to fulfill my need. – The data is being persisted to the main LSPS_DS data source, but I am needing the Shared Record to persist to a different/secondary data source that has been defined in the openejb.

How can this be achieved?

(all tables and columns are the same between the two data sources, I am just needed to persist to the secondary data source vs the main LSPS_DS data source. - I am using 3.1 PDS, Build: 3.1.1024)

Thank you in advance!

Roman Kubascik
 
Posts: 51
Joined: Thu Apr 16, 2015 9:05 am

Re: Persist Shared Record to secondary datasource

Mon Mar 27, 2017 4:33 pm

Hi Eric,

Yes, it's possible, you can set database/datasource for shared records which are defined in the datatypes file.

1. Open the datatypes definition for editing.
2. In the Outline view, select the root Data Types item.
3. In the Properties windows, change the Database property.

More details you can find in the documentation.

Regards,
Roman

Byron Glueck
 
Posts: 84
Joined: Thu Apr 26, 2012 8:17 pm

Re: Persist Shared Record to secondary datasource

Thu Mar 30, 2017 5:05 pm

If there is an existing modeled relationship between shared record A to a shared record B, then the relationship navigation will be broken by separating the records into different data type configurations (sources).

In this case, one should consider storing instead the identifier of the foreign/related record(s) and programmatically performing a find() operation to retrieve the related record(s), as necessary.

eric.graham
 
Posts: 53
Joined: Tue May 13, 2014 12:20 pm

Re: Persist Shared Record to secondary datasource

Mon Apr 03, 2017 8:56 pm

Roman / Byron -
Thank you both for your advise on this issue. We were ableto achieve our desired needs, based on both you advise on spitting the datatypes to point to the desired Schema. ;)

Thanks again for your help!

Return to Integration

Who is online

Users browsing this forum: No registered users and 1 guest