[英]Remove MySql database table on remote server from C# application
If I can create MySql
database table on remote server from C#
desktop application string createTableQuery = string.Format(table, tableName);
如果我可以从C#
桌面应用程序string createTableQuery = string.Format(table, tableName);
创建远程服务器上的MySql
数据库表string createTableQuery = string.Format(table, tableName);
and var cmd = new MySql.Data.MySqlClient.MySqlCommand(createTableQuery, conn);
和var cmd = new MySql.Data.MySqlClient.MySqlCommand(createTableQuery, conn);
Then how do I remove table
from MySql
database by tableName
那么如何通过tableName
从MySql
数据库中删除table
Any guide, advice or example would helpful 任何指南,建议或示例都会有所帮助
Just write an inline query with DROP TABLE TABLENAME command and pass it as an argument to your MYSQLCOMMAND. 只需使用DROP TABLE TABLENAME命令编写内联查询,并将其作为参数传递给MYSQLCOMMAND。 If the user has necessary permission, It will drop the table. 如果用户具有必要的权限,它将删除该表。 Check here 点击这里
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.