Dear sir/madam,
this is vishnuvardhan.i have problem in executing my program.the output which is need to me is one field delete from row of a db1 table.but at the execution time i founnd total row deleted.but i need to delete one field only in row.
i got error in button 1 clicks. on that delete from temp_user_id qurey.
Could you please check and resolve my problem.
THANKS IN ADVANCE.
Problem with delete query in c# .net.
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.

Micke BlomqvistRank #1,660 · 923 reputationPosted Feb 10, 2011, 9:04 PM EST
You are not able to delete a column in you db in the sence you are meaning here. You can remove it by dropping it, but I guess thats not your intention here. I guess you want to set the column/field to blank or perhaps NULL. (If NULL'able)
Try (where @Token is your string a variable)
update temp_user_id set your_field = '' where token_no = @Token
or
update temp_user_id set your_field = NULL where token_no = @Token
Did I understand your question correctly?
vishnuvardhan diyyala35 reputationPosted Feb 12, 2011, 8:41 AM EST