IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Getting SQLCODE -530


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
soumyaranjan007

New User


Joined: 30 Aug 2006
Posts: 30
Location: mumbai

PostPosted: Mon Apr 16, 2007 1:31 pm
Reply with quote

Hi,

we are getting SQLCODE -530. if anybody have idea in resolution. help me out.

thanks,
soumya
Back to top
View user's profile Send private message
ragganga

New User


Joined: 22 Jan 2007
Posts: 18
Location: bangalore

PostPosted: Mon Apr 16, 2007 1:54 pm
Reply with quote

Hi Soumya,

SQLCODE = -530

Explanation - An UPDATE or INSERT operation attempted to place a value in a foreign key of the object table; however, this value was not equal to some value of the primary key of the parent table.When a row is inserted into a dependent table, the insert value of a foreign key must be equal to the value of the primary key of some row of the parent table in the associated relationship.When the value of the foreign key is updated, the update value of a foreign key must be equal to the value of the primary key of some row of the parent table of the associated relationship.

Response - Examine the insert or update value of the foreign key first, and then compare it with each of the primary key values of the parent table to determine the cause of the problem.

I think it is enough to solve your error

Regards
Raghu
Back to top
View user's profile Send private message
mkk157

Active User


Joined: 17 May 2006
Posts: 310

PostPosted: Mon Apr 16, 2007 1:59 pm
Reply with quote

Hi Sowmyaranjan,

I never heard about the resolution. Can u explain ur problem a bit clearly. The follwoing information about the SQLCODE -530 may help u.


-530 THE INSERT OR UPDATE VALUE OF FOREIGN KEY constraint-name IS
INVALID

Explanation: An UPDATE or INSERT operation attempted to place a value in
a foreign key of the object table; however, this value was not equal to
some value of the parent key of the parent table.

When a row is inserted into a dependent table, the insert value of a
foreign key must be equal to the value of the parent key of some row of
the parent table in the associated relationship.

When the value of the foreign key is updated, the update value of a
foreign key must be equal to the value of the parent key of some row of
the parent table of the associated relationship.

System Action: The UPDATE or INSERT statement cannot be executed. The
object table is unchanged.

Programmer Response: Examine the insert or update value of the foreign
key first, and then compare it with each of the parent key values of the
parent table to determine the cause of the problem.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts SQLCODE = -122 while using the scalar... DB2 4
No new posts SQLCODE = -16002 when using XMLEXISTS DB2 1
No new posts Is SQLCODE -811 possible while fetchi... DB2 1
No new posts SQLCODE=-204 SQLSTATE=42704 DB2 4
No new posts Getting sqlcode 805 while executing R... DB2 10
Search our Forums:

Back to Top