Skip to main content
Question

How to create foreign key with oracle writer after creating tables ? (one to one)


Forum|alt.badge.img

Table1

pTable2

table 2 

Reader data from soap and writer is oracle spatial object.

I use inline querier and featureMerger for using xml hierarcy that is "STATUS_REASON_SEQ_ID ". So, I merged two tables and created. But I expect to see foreign key(references Table2 (SEQ_ID)) in Table1.

What should I use in this case. ?

2 replies

takashi
Influencer
  • January 5, 2022

Hi @ikubra800​ , I think you can execute a SQL statement to add a foreign key to the Table 2 by setting the statement to the "SQL to Run After Write" parameter in the Oracle writer.

Alternatively, you can also execute SQL statements to create the destination tables including the foreign key constraint beforehand, by setting the "SQL to Run Before Write" parameter.


Forum|alt.badge.img
  • Author
  • January 6, 2022

Thanks for the response @Takashi Iijima​ 

I solved with two FeatureWriter and SQLExecutor.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings