如何从任何表中删除任何行 [英] How do I delete any row from any table
本文介绍了如何从任何表中删除任何行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
有人可以帮我查询一下,问题是如何通过删除按钮从任何表中删除任何行,该记录也应该在数据库中删除,当我点击menustrip我的表将显示在datagridview中,我希望从这些表中的任何一个表中删除一个特定的行,所以请帮助我???
< b>我尝试了什么:
i已尝试过特定的表
Hello there,
Can someone please help me with my query ,the prblem is how can i delete any row from any table through delete button an the record should also be deleted in the db, When i click on the menustrip my tables will be displayed in datagridview and i want a particular row to be deleted from anyone of those tables so please help me ???
What I have tried:
i have tried for a particular table
推荐答案
您需要构建标准的DELETE查询字符串并对数据库执行它。这是简单的字符串操作。
You need to build a standard DELETE query string and execute it against the database. This is simple string manipulation.
DELETE FROM [tablename] WHERE [matchingExpression]
你有提供表名和表达式以标识要删除的记录。
You have to supply the tablename and the expression to identify the record you want to delete.
这篇关于如何从任何表中删除任何行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文