![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | Linq To Sql using store proc is calling update instead of delete I have a schema that has a parent child relationship. I have decided to implelment operations using stored procs for the child table(view). I wrote my custom insert update and delete and then mapped them to my view using the configure behavior dialog. At first I got an "An attempt was made to remove a relationship between a Parent and a Child. ... OwnerParentId) cannot be set to null" when I attempted to delete a child record. After a bit of research I changed my schema association and added a DeleteOnNull. This made no change. I still got the error. I then made by child FK field nullable. It won't ever be null but OK. This made the error disapear. Instead it just doesn't work. I check the dbcontext log and found instead of calling my delete stored proc it was calling my update stored proc. I did try a manual delete by calling DeleteOnSubmit but when I delete it using the UI (winform grid) it calls update instead of delete. Any Ideas? |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| [LINQ TO SQL] Probleme for update a child element | .NET General | |||
| Disable Media Center Store Update Manager? | Vista General | |||
| LinQ. update column with auto generated value | .NET General | |||
| Update to WMUtil to remove blank files from the message store | Vista mail | |||