Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27087

VS 2010 error at save between 2 tables they have relationship one-to-many

$
0
0
hi all

I have 2 tables Customers and Orders it have relationship one-to-many and i set the cascade between tables. i add both tables to one form and i set EndEdit event to the CustomerBindingSource owing to Saves the new record in Customers before save new record to the Orders but i receives error :
A foreign key value cannot be inserted because a corresponding primary key value does not exist.
I did no know what is wrong !




Attachment 94145
Attached Files

Viewing all articles
Browse latest Browse all 27087

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>