public DataSet QueryDataSet(string cmdText, string tblName) { try { DataSet ds = new DataSet(); if (tblName != string.Empty) { ds = _AdoTemplate.DataSetCreate(CommandType.Text, cmdText, new string[] { tblName }); } else { ds = _AdoTemplate.DataSetCreate(CommandType.Text, cmdText); } return(ds); } catch (Exception e) { dsExceptionHandler.HandleException(e); ReConnection(e); throw e;// new Goodway.CommonModel.Exception.DbException(DbResult.SqlError, e.Message ?? "" + Environment.NewLine + e.StackTrace ?? "", cmdText); } }
public DataSet Get(string name) { return(AdoTemplate.DataSetCreate(CommandType.Text, string.Format("SELECT * FROM UserTable WHERE UserName = '******'", name))); }
public DataSet GetCustomers(string dataSetName) { return(AdoTemplate.DataSetCreate(CommandType.Text, selectAll, new string[] { dataSetName })); }
/// <summary> /// 执行sql语句 /// </summary> /// <param name="cType">执行类型</param> /// <param name="sql">sql语句</param> /// <returns>结果集DataSet</returns> public DataSet ExecteSqlGetDataSet(CommandType cType, string sql) { return(AdoTemplate.DataSetCreate(CommandType.Text, sql)); }
public DataSet GetCustomers() { return(AdoTemplate.DataSetCreate(CommandType.Text, selectAll)); }