Jessie
Jessie

Reputation: 11

Accessing Source Schema Name

I have a subscription that calls a ‘After Refresh’ User-Exit stored procedure from Management Console. Now, I can access various system variables like source and target table names using ‘s$srcTabId’ and ‘s$tgtTabId’ respectively. But I could not find a variable, system or journal, that gives me the source schema name. Is there any way to access the source schema name from stored procedure?

Upvotes: 0

Views: 25

Answers (1)

Oak Zoom
Oak Zoom

Reputation: 24

Unfortunately, this is not available for the platforms you are using. Below is a link to the fields supported:

http://publib.boulder.ibm.com/infocenter/iidr/v10r1m2/topic/com.ibm.cdcdoc.cdcformssql.doc/concepts/retrievingjournalcontrolfieldsusingthejprefix_jsql.html?resultof=%22%6a%6f%75%72%6e%61%6c%22%20%22%63%6f%6e%74%72%6f%6c%22%20%22%66%69%65%6c%64%73%22%20%22%66%69%65%6c%64%22%20

Given this, a (admittedly not great) work-around would be to have a script on the source which gets the tables schema names and writes it to a table that is mirrored to the target. You could then do a look up on this target table.

Upvotes: 1

Related Questions