我正在尝试使用 Query 中的Fill
查询。我不明白的是,当我已经给出了要查询的表时,为什么我必须在 中明确说明表名。DataSet
SqlDataAdaptor
Fill
SqlDataAdapter
看下面的代码,查询字符串中已经有“FooTable”了,为什么在SqlDataAdapter.Fill中又需要“FooTable”呢?
SqlDataAdapter da = new SqlDataAdapter("SELECT * FROM FooTable", connectionString);
DataSet ds = new DataSet();
da.Fill(ds, "FooTable");