コード例 #1
0
        public UtlParameter Add(string parameterName, UtlType parameterType, int parameterSize, string sourceColumn)
        {
            UtlParameter parameter = new UtlParameter(parameterName, parameterType, parameterSize, sourceColumn);

            this.Add(parameter);
            return(parameter);
        }
コード例 #2
0
        public UtlParameter Add(string parameterName, UtlType parameterType, int parameterSize)
        {
            UtlParameter parameter = new UtlParameter(parameterName, parameterType, parameterSize);

            this.Add(parameter);
            return(parameter);
        }
コード例 #3
0
ファイル: SqlType.cs プロジェクト: cwdotson/FwNs
        public static SqlType GetUtlType(UtlType dbTypeNumber)
        {
            switch (dbTypeNumber)
            {
            case UtlType.Null:
                return(SqlAllTypes);

            case UtlType.Boolean:
                return(SqlBoolean);

            case UtlType.TinyInt:
                return(Tinyint);

            case UtlType.SmallInt:
                return(SqlSmallint);

            case UtlType.Int:
                return(SqlInteger);

            case UtlType.BigInt:
                return(SqlBigint);

            case UtlType.Decimal:
            case UtlType.Money:
                return(SqlDecimalDefault);

            case UtlType.Double:
                return(SqlDouble);

            case UtlType.Char:
                return(SqlChar);

            case UtlType.VarChar:
            case UtlType.VarCharIngnoreCase:
                return(SqlVarchar);

            case UtlType.UniqueIdentifier:
                return(SqlUniqueIdentifier);

            case UtlType.Variant:
                return(Other);

            case UtlType.Time:
                return(SqlTime);

            case UtlType.TimeTZ:
                return(SqlTimeWithTimeZone);

            case UtlType.TimeStamp:
                return(SqlTimestamp);

            case UtlType.TimeStampTZ:
                return(SqlTimestampWithTimeZone);

            case UtlType.Date:
                return(SqlDate);

            case UtlType.IntervalDS:
                return(SqlIntervalDayToSecond);

            case UtlType.IntervalYM:
                return(SqlIntervalYearToMonth);

            case UtlType.Binary:
                return(SqlBinary);

            case UtlType.VarBinary:
                return(SqlVarbinary);

            case UtlType.Blob:
                return(SqlBlob);

            case UtlType.Clob:
                return(SqlClob);
            }
            throw new NotSupportedException(string.Format("DbType :{0}", dbTypeNumber));
        }
コード例 #4
0
        private SqlType UtlType2SqlType(UtlType type)
        {
            switch (type)
            {
            case UtlType.Null:
                return(null);

            case UtlType.Boolean:
                return(SqlType.SqlBoolean);

            case UtlType.TinyInt:
                return(SqlType.Tinyint);

            case UtlType.SmallInt:
                return(SqlType.SqlSmallint);

            case UtlType.Int:
                return(SqlType.SqlInteger);

            case UtlType.BigInt:
                return(SqlType.SqlBigint);

            case UtlType.Decimal:
                return(SqlType.SqlDecimal);

            case UtlType.Double:
                return(SqlType.SqlDouble);

            case UtlType.Char:
                return(SqlType.SqlChar);

            case UtlType.VarChar:
                return(SqlType.SqlVarchar);

            case UtlType.VarCharIngnoreCase:
                return(SqlType.VarcharIgnorecase);

            case UtlType.UniqueIdentifier:
                return(SqlType.SqlUniqueIdentifier);

            case UtlType.Variant:
                return(SqlType.Other);

            case UtlType.Time:
                return(SqlType.SqlTime);

            case UtlType.TimeTZ:
                return(SqlType.SqlTimeWithTimeZone);

            case UtlType.TimeStamp:
                return(SqlType.SqlTimestamp);

            case UtlType.TimeStampTZ:
                return(SqlType.SqlTimestampWithTimeZone);

            case UtlType.Date:
                return(SqlType.SqlDate);

            case UtlType.IntervalDS:
                return(SqlType.SqlIntervalDayToSecond);

            case UtlType.IntervalYM:
                return(SqlType.SqlIntervalYearToMonth);

            case UtlType.Binary:
            case UtlType.VarBinary:
                return(SqlType.SqlBinary);

            case UtlType.Blob:
                return(SqlType.SqlBlob);

            case UtlType.Clob:
                return(SqlType.SqlClob);

            case UtlType.Money:
                return(SqlType.SqlDecimal);
            }
            return(SqlType.Other);
        }