コード例 #1
0
ファイル: BQLValueItem.cs プロジェクト: guojianbin/buffalobro
        /// <summary>
        /// EndWith条件
        /// </summary>
        /// <param name="item">条件</param>
        /// <returns></returns>
        public BQLConditionItem EndWith(object item)
        {
            BQLValueItem oValue = BQLValueItem.ToValueItem(item);

            oValue.ValueDbType = this.ValueDbType;
            return(new BQLConditionItem(this, new BQLValueItem[] { oValue }, BQLConditionManager.DoEndWith));
        }
コード例 #2
0
ファイル: BQLValueItem.cs プロジェクト: guojianbin/buffalobro
        /// <summary>
        /// Between条件
        /// </summary>
        /// <param name="star">开始值</param>
        /// <param name="end">结束值</param>
        /// <returns></returns>
        public BQLConditionItem Between(object star, object end)
        {
            BQLValueItem oValue1 = BQLValueItem.ToValueItem(star);
            BQLValueItem oValue2 = BQLValueItem.ToValueItem(end);

            oValue1.ValueDbType = this.ValueDbType;
            oValue2.ValueDbType = this.ValueDbType;
            return(new BQLConditionItem(this, new BQLValueItem[] { oValue1, oValue2 }, BQLConditionManager.DoBetween));
        }
コード例 #3
0
ファイル: BQLValueItem.cs プロジェクト: guojianbin/buffalobro
        /// <summary>
        /// 查找字符
        /// </summary>
        /// <param name="value">要查找的字符</param>
        /// <param name="start">起始位置</param>
        /// <returns></returns>
        public CsqCommonFunction IndexOf(object value, BQLValueItem start)
        {
            BQLValueItem oValue = BQLValueItem.ToValueItem(value);;

            start.ValueDbType = DbType.Int32;
            if (oValue.ValueDbType == DbType.Object)
            {
                oValue = DbType.String;
            }
            CsqCommonFunction handle = new CsqCommonFunction(new BQLValueItem[] { oValue, this, start }, DBMathFunction.IndexOf, DbType.Int32);

            //handle.ValueDataType = DefaultType.IntType;
            handle.ValueDbType = DbType.Int32;
            return(handle);
        }