string sql = "SELECT * FROM User";
"FROM子句语法错误"
解决:
如ID,User之类的SQL的关键字,不能直接这样写Select * from User应该写为Select * from [User]事实上,规范的写法也应该是每个字段或是视图名、表名也要用[]如SELECT [id],[name] FROM [user] ORDER BY [id] DESC