cancel
Showing results for 
Search instead for 
Did you mean: 

JDBC : Unique key

Former Member
0 Kudos

Hello

1) Wanted to understand when we insert record into a oracle table from PI , is primary key always required to be created in table structure ?

2) for updates a key would be looked , if a record already exists it would be an update. what is the command for inserting into a table which has to be put in mapping logic ? we have pi 7.1

3) can a combination of 5 keys be like a unique key defined in PI ?

Thnx

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

1) Wanted to understand when we insert record into a oracle table from PI , is primary key always required to be created in table structure ?

No, key is not mandatory. But I believe that you will always update records with some conditions. If you always want to update all the existing records without any conditions, then it's a weird but still technically possible case.

2) for updates a key would be looked , if a record already exists it would be an update. what is the command for inserting into a table which has to be put in mapping logic ? we have pi 7.1

I guess you are missing the concepts of DB and your question is confusing. You can use key depending on the query that you have formed, for update / insert.

Elaborate your requirement. if you have a SQL query, provide it here.

3) can a combination of 5 keys be like a unique key defined in PI ?

Yes, you can define 'n' number of keys in the mapping.

Former Member
0 Kudos

for second question I was implying , I want to update a record if it exists else I want to insert it. how do i achieve this ? Thanks

Former Member
0 Kudos

for second question I was implying , I want to update a record if it exists else I want to insert it. how do i achieve this ?

Use UPDATE_INSERT in the mapping.

Refer :-

http://help.sap.com/saphelp_nw2004s/helpdata/en/2e/96fd3f2d14e869e10000000a155106/content.htm

(Statement # 1).

Answers (0)