asp.net中DataSet的问题
程序代码:
MySQLConnection conn = new MySQLConnection(new MySQLConnectionString("192.168.0.56", "antshop", "root", "qwe123").AsString); conn.Open(); string sql = "SELECT a.salesman,SUM(b.qty/b.qtyOfPackage),b.expiryDate FROM saleorderbill a,saleorderbilldetail b,brand c,goods d WHERE a.billCode=b.billCode AND b.goods_id=d.id AND d.brand_id=c.id AND b.money<>0 AND a.salesman='刘俊斌' GROUP BY a.salesman,c.`name`,b.expiryDate"; MySQLCommand comm = new MySQLCommand(sql, conn); comm.ExecuteNonQuery(); MySQLDataAdapter da = new MySQLDataAdapter(); da.SelectCommand = comm; DataSet ds = new DataSet(); da.Fill(ds);
我连接另一个数据库可以存储到ds中,但是这个为什么不行,求原因……