当前位置: 首页>>代码示例>>C#>>正文


C# QueryBuilder.AppendWhereInteger方法代码示例

本文整理汇总了C#中QueryBuilder.AppendWhereInteger方法的典型用法代码示例。如果您正苦于以下问题:C# QueryBuilder.AppendWhereInteger方法的具体用法?C# QueryBuilder.AppendWhereInteger怎么用?C# QueryBuilder.AppendWhereInteger使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在QueryBuilder的用法示例。


在下文中一共展示了QueryBuilder.AppendWhereInteger方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetActive

 public TaskObjectCollection GetActive()
 {
     TaskObjectCollection tasks = new TaskObjectCollection();
     QueryBuilder builder;
     try
     {
         builder = new QueryBuilder();
         builder.Append(this.BaseQuery(false, 0));
         builder.AppendWhereInteger(TaskObject.STATUS, (int)TIS.Framework.Common.Enumeration.Task.Status.Open, QueryBuilder.ParameterLocation.FIRST_LAST);
         builder.AppendOrderBy(TaskObject.CREATION_DATE, QueryBuilder.OrderByType.ASC, QueryBuilder.ParameterLocation.FIRST_LAST);
         tasks = TaskConvertor.DataTableToCollection(this.ExecuteDataSet(builder.Query, false).Tables[0]);
     }
     catch (System.Exception exception1)
     {
         Exception innerException = exception1;
         throw new Exception(MethodBase.GetCurrentMethod().Name, innerException);
     }
     return tasks;
 }
开发者ID:GianiWVL,项目名称:VUYLSTEKE,代码行数:19,代码来源:TaskDataService.cs

示例2: GetForbiddenFuelNotSendMail

        public FuelObjectCollection GetForbiddenFuelNotSendMail(string supplier, int transc_NawID, DateTime dateFrom, DateTime dateTo)
        {
            FuelObjectCollection fuels;
            QueryBuilder builder;
            try
            {
                builder = new QueryBuilder();
                builder.Append(this.BaseQuery(false, 0));
                builder.AppendWhereString("1", "1", QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.FIRST);
                if (supplier != "" & supplier != null)
                    builder.AppendWhereString(FuelObject.SUPPLIER, supplier, QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.MIDDLE);
                if (transc_NawID != -1)
                    builder.AppendWhereInteger(FuelObject.TRANSC_NAWID, transc_NawID, QueryBuilder.ParameterLocation.MIDDLE);
                if (dateFrom != DateTime.MinValue)
                    builder.AppendWhereString(FuelObject.DATE, dateFrom.Year + "-" + dateFrom.Month + "-" + dateFrom.Day, QueryBuilder.ComparisonOperators.GreaterAndEqual, QueryBuilder.ParameterLocation.MIDDLE);
                if (dateTo != DateTime.MaxValue)
                    builder.AppendWhereString(FuelObject.DATE, dateTo.Year + "-" + dateTo.Month + "-" + dateTo.Day, QueryBuilder.ComparisonOperators.SmallerAndEqual, QueryBuilder.ParameterLocation.MIDDLE);

                builder.Append(" AND " + FuelObject.DATEMAIL_FORBIDDENFUELING + " IS NULL ");

                builder.AppendOrderBy(FuelObject.DATE, QueryBuilder.OrderByType.DESC, QueryBuilder.ParameterLocation.FIRST_LAST);
                return fuels = FuelConvertor.DataTableToCollection(this.ExecuteDataSet(builder.Query, false).Tables[0]);

            }
            catch (System.Exception exception1)
            {
                throw new Exception(MethodBase.GetCurrentMethod().Name, exception1);
            }
            return fuels;
        }
开发者ID:GianiWVL,项目名称:VUYLSTEKE,代码行数:30,代码来源:FuelDataService.cs

示例3: GetFilter

        public FuelObjectCollection GetFilter(string supplier, int fuelType,
                                               string employee, string vehicle, DateTime dateFrom, DateTime dateTo,
                                                        Boolean privateFuel)
        {
            FuelObjectCollection fuels;
            QueryBuilder builder;
            try
            {
                builder = new QueryBuilder();
                builder.Append(this.BaseQuery(false, 0));
                builder.AppendWhereString("1", "1", QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.FIRST);
                if (supplier != "" & supplier != null)
                    builder.AppendWhereString(FuelObject.SUPPLIER, supplier, QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.MIDDLE);
                if (fuelType != -1)
                    builder.AppendWhereInteger(FuelObject.FUELTYPE, Convert.ToInt16(fuelType), QueryBuilder.ParameterLocation.MIDDLE);
                if (employee != "" & employee != null)
                    builder.AppendWhereString(FuelObject.EMPLOYEE, employee, QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.MIDDLE);
                if (vehicle != "" & vehicle != null)
                    builder.AppendWhereString(FuelObject.VEHICLE_LICENSEPLATE, vehicle, QueryBuilder.ComparisonOperators.Equal, QueryBuilder.ParameterLocation.MIDDLE);
                if (dateFrom != DateTime.MinValue)
                    builder.AppendWhereString(FuelObject.DATE, dateFrom.Year + "-" + dateFrom.Month + "-" + dateFrom.Day, QueryBuilder.ComparisonOperators.GreaterAndEqual, QueryBuilder.ParameterLocation.MIDDLE);
                if (dateTo != DateTime.MaxValue)
                    builder.AppendWhereString(FuelObject.DATE, dateTo.Year + "-" + dateTo.Month + "-" + dateTo.Day, QueryBuilder.ComparisonOperators.SmallerAndEqual, QueryBuilder.ParameterLocation.MIDDLE);

                builder.AppendWhereBoolean(FuelObject.PRIVATE_TANKING, privateFuel, QueryBuilder.ParameterLocation.LAST);
                builder.AppendOrderBy(FuelObject.DATE, QueryBuilder.OrderByType.DESC, QueryBuilder.ParameterLocation.FIRST_LAST);
                return fuels = FuelConvertor.DataTableToCollection(this.ExecuteDataSet(builder.Query, false).Tables[0]);

            }
            catch (System.Exception exception1)
            {
                throw new Exception(MethodBase.GetCurrentMethod().Name, exception1);
            }
            return fuels;
        }
开发者ID:GianiWVL,项目名称:VUYLSTEKE,代码行数:35,代码来源:FuelDataService.cs

示例4: GetByVehicle

 public VehicleMileageObjectCollection GetByVehicle(VehicleObject vehicle)
 {
     VehicleMileageObjectCollection vehicleMileages = new VehicleMileageObjectCollection();
     QueryBuilder builder;
     try
     {
         if (vehicle.VehicleTransicsLink != null)
         {
             builder = new QueryBuilder();
             builder.Append(this.BaseQuery(false, 0));
             builder.AppendWhereInteger(VehicleMileageObject.TRANSI_TNR_MAT, vehicle.VehicleTransicsLink.Transi_TNR_mat, QueryBuilder.ParameterLocation.FIRST_LAST);
             builder.AppendOrderBy(VehicleMileageObject.DATE, QueryBuilder.OrderByType.DESC, QueryBuilder.ParameterLocation.FIRST_LAST);
             vehicleMileages = VehicleMileageConvertor.DataTableToCollection(this.ExecuteDataSet(builder.Query, false).Tables[0]);
         }
     }
     catch (System.Exception exception1)
     {
         throw new Exception(MethodBase.GetCurrentMethod().Name, exception1);
     }
     return vehicleMileages;
 }
开发者ID:GianiWVL,项目名称:VUYLSTEKE,代码行数:21,代码来源:VehicleMileageDataService.cs


注:本文中的QueryBuilder.AppendWhereInteger方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。