//两个dataset合并
SqlHelper.conn conn = new SqlHelper.conn();
DataSet dsdept = conn.GetDataSet("select top 5 dt_id as id, dt_name as name, 1 as flag from deptinfo", "deptinfo");
DataSet dsuser = conn.GetDataSet("select top 5 ui_id as id, ui_username as name, 0 as flag from userinfo", "deptinfo");
dsuser.AcceptChanges();
dsdept.Merge(dsuser, true, MissingSchemaAction.AddWithKey);
this.GridView1.DataSource = dsdept;
this.GridView1.DataBind();
注意:表名要相同