here form code is there plz help me...
i can't save the data
i am having this error so what can i doo...
here form code is there plz help me...

here form code is there plz help me...
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Safeer SafeerPosted Aug 1, 2013, 2:46 AM
Sunny SharmaPosted Jul 31, 2013, 7:46 AM
The way a Foreign Key works is it cannot have a value in that column that is not also in the primary key column of the referenced table.
In your table dbo.tbl_house you have a foreign key reference of column 'house_id' to the table tbl_member. When you're trying to insert the values it is checking the "house_id" to be already in there inside 'tbl_member'.
Please ensure that the house_id you're trying to insert is already in 'tbl_member' and your query will work.
Happy Coding :)