将截断字符串或二进制数据。
crs = comd.ExecuteReader();return crs;
}
public DataSet getRS1(string sql)
{
DataSet ds = new DataSet();
SqlDataAdapter da = new SqlDataAdapter();
SqlConnection conn = this.getConnection();
conn.Open();
SqlCommand comd = conn.CreateCommand();
= sql;
da.SelectCommand = comd;
da.Fill(ds);
return ds;
}
public bool update(string sql)
{
SqlConnection conn = null;
bool flag = false;
conn = this.getConnection();
SqlCommand comd = conn.CreateCommand();
= sql;
conn.Open();
Thread.Sleep(1);
int s = comd.ExecuteNonQuery();------>将截断字符串或二进制数据。语句已终止
if (s <= 0)
flag = false;
else
flag = true;
return flag;
}
}
}