示例#1
0
        protected OracleDataProvider(string name, MappingSchema mappingSchema)
            : base(name, mappingSchema)
        {
            SqlProviderFlags.IsCountSubQuerySupported    = false;
            SqlProviderFlags.IsIdentityParameterRequired = true;

            SqlProviderFlags.MaxInListValuesCount = 1000;

            SetCharField("Char", (r, i) => r.GetString(i).TrimEnd());
            SetCharField("NChar", (r, i) => r.GetString(i).TrimEnd());

            _sqlOptimizer = new OracleSqlOptimizer(SqlProviderFlags);
        }
示例#2
0
        protected OracleDataProvider(string name, MappingSchema mappingSchema)
            : base(name, mappingSchema)
        {
            //SqlProviderFlags.IsCountSubQuerySupported    = false;
            SqlProviderFlags.IsIdentityParameterRequired = true;

            SqlProviderFlags.MaxInListValuesCount = 1000;

            SetCharField("Char", (r, i) => r.GetString(i).TrimEnd());
            SetCharField("NChar", (r, i) => r.GetString(i).TrimEnd());

//			ReaderExpressions[new ReaderInfo { FieldType = typeof(decimal), ToType = typeof(TimeSpan) }] =
//				(Expression<Func<IDataReader,int,TimeSpan>>)((rd,n) => new TimeSpan((long)rd.GetDecimal(n)));

            _sqlOptimizer = new OracleSqlOptimizer(SqlProviderFlags);
        }
示例#3
0
		public OracleDataProvider(string name)
			: base(name, null)
		{
			//SqlProviderFlags.IsCountSubQuerySupported    = false;
			SqlProviderFlags.IsIdentityParameterRequired = true;

			SqlProviderFlags.MaxInListValuesCount = 1000;

			SetCharField("Char",  (r,i) => r.GetString(i).TrimEnd(' '));
			SetCharField("NChar", (r,i) => r.GetString(i).TrimEnd(' '));
			SetCharFieldToType<char>("Char",  (r, i) => DataTools.GetChar(r, i));
			SetCharFieldToType<char>("NChar", (r, i) => DataTools.GetChar(r, i));

			//			ReaderExpressions[new ReaderInfo { FieldType = typeof(decimal), ToType = typeof(TimeSpan) }] =
			//				(Expression<Func<IDataReader,int,TimeSpan>>)((rd,n) => new TimeSpan((long)rd.GetDecimal(n)));

			_sqlOptimizer = new OracleSqlOptimizer(SqlProviderFlags);
		
//			SetField<IDataReader,decimal>((r,i) => OracleTools.DataReaderGetDecimal(r, i));
		}