一:
public DataSet GetDataSet(String SqlString) { DataSet dataset = new DataSet(); Open(); try { SqlDataAdapter adapter = new SqlDataAdapter(SqlString, Connection); adapter.SelectCommand.CommandTimeout = 60000; adapter.Fill(dataset); } catch (Exception e) { log.WriteLog(EventLogEntryType.Warning, "GetDataSet失败,SqlString=" + SqlString + ",系统异常信息:" + e.Message); } finally { Close(); } return dataset; }