Click here to Skip to main content
15,885,244 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have created a dataset for my table tbl_Cust.In code created a tableadapter object adapter n a typed datatable custtb.then i have inserted 2 rows, updated 2 rows and deleted 2 rows in my datatable custdb thru code.
then i called adapter.Update(custtb) to update same in my DB.
Inserted&Updated records are reflecting in DB. But the deleted one are not actually removed from DB.

The code for DB update is like
this.dataSetDataTableFromDBBindingSource.EndEdit();
this.Validate();
this.adapter.Update(this.custtb);

my delete command of adapter is correct.I cant use delete method of adapter and delete each rows as i wanna do it in bulk.
Anyone idea on where it goes wrong?????
Thanks in advance
Posted
Updated 10-Feb-11 19:56pm
v2

Der Friend
If there is any relation ship then it may cause problem(hope you know).
If you are using stored procedure to perform operation then check the stored procedure so that the comparison is correct or not

regards
Vipin Kumar
 
Share this answer
 
Thanks Vipin,

But Im using direct SQL command, not a SP. Also there is no relationship as my dataset stands for a single table.

Nishitha
 
Share this answer
 
Hope this[^] might give you an idea.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900