http://bbs.csdn.net/topics/360256700
public DataSet xxx(DateTime start, DateTime end, string type) { string[,] strArray = new string[6, 2] {{"0", "11"}, {"1", "11"}, {"2", "22"}, {"3", "11"}, {"4", "11"}, {"5", "11"}}; DataSet dst = new DataSet(); DbCore dbCore = new DbCore(DatabaseType.Oracle, BaseEntity.GetConnectionString()); dbCore.Open(); dst = dbCore.Select().SelectColumns(new string[]{A.s_FEECELLED, B.s_SSXCELLED, B.s_MSPHONE1, B.s_MSPHONE2, B.s_MSPHONE3, B.s_MSPHONE4, A.s_ADDDATE, A.s_ORDERFLAG, A.s_RESPTIME}) .From(new string[]{A.s_TableName, B.s_TableName}) .Where().ConditionAndEqual(A.s_ORDERTYPE, type) .ConditionAndBetweenAnd(A.s_ADDDATE, start.ToString(), end.ToString()) .ConditionColumnAndEqual(A.s_FEECELLED, B.s_ADMINCELLING) .ConditionColumnAndEqual(A.s_USECELLED, B.s_SSXCELLED) .ConditionAndNotIn(A.s_FEECELLED, new string[] { "136xxxx", "135xxxx", "135xxxx", "136xxxx" }).ExecuteDataSet(); dbCore.Close(); DataTable dt = TableHelp.ReplacleTableColValue(dst.Tables[0], dst.Tables[0].Columns["ORDERFLAG"], strArray); // TableHelp.SortTable(dst.Tables[0], dst.Tables[0].Columns[6]); TableHelp.SortTable(dt, "ADDDATE", SortDirection.Asc);//"ORDERFLAG", SortDirection.Asc);//, // TableHelp.SortTableAsc(dst.Tables[0], dst.Tables[0].Columns["ADDDATE"], dst.Tables[0].Columns["ORDERFLAG"]); return dst; }