I have installed dotConnect for Oracle Professional (7.7.257).
Till now, I was using version 5.70 in my project without problems.
After updating to 7.7 version, when I launch my application I obtain two critial errors.
The first one:
Code: Select all
var query = from a in Context.MYTABLE
where a.FIELD1 == "A"
select new
{
Sel = false,
NewProperty1 = (int)a.USCAJA_0,
};
USCAJA_0 is a Decimal.
And the second one is similar:
Code: Select all
IQueryable<MyType> arts = context.MYTABLE2
.GroupBy(c => new { c.DESART_0, c.ARTICULO_0 })
.OrderBy(c => c.Key.DESART_0)
.Select(c => new MyType
{
Code = c.Key.ARTICULO_0,
Desc = c.Key.DESART_0,
Quantity = (decimal) c.Sum(d => d.CAJDISTEC_0),
MinFecha = c.Min(d => d.FECHAMIN_0)
});
CAJDISTEC_0 is an Int32 and Quantity is a Decimal property.
This code was working perfectly with version 5.70.
If I replace (int) and (decimal) by Convert.ToInt32() and Convert.ToDecimal, all works perfect again.
But I have a lot of casts in my app and in other places this code works perfect. So I don't know what is the problem or if it is a bug, and where should I replace (int) and (decimal).
The exception gives me this stacktrace:
Code: Select all
at Devart.Data.Linq.Engine.bh.b(Type A_0, Type A_1, Boolean A_2)
at Devart.Data.Linq.Engine.bh.a(u A_0, LocalBuilder A_1)
at Devart.Data.Linq.Engine.bh.b(bi A_0)
at Devart.Data.Linq.Engine.bh.e(bi A_0)
at Devart.Data.Linq.Engine.bh.a(SqlExpression A_0, Boolean A_1)
at Devart.Data.Linq.Engine.z.a(cj A_0, SqlExpression A_1)
at Devart.Data.Linq.Engine.dr.a(f A_0)
at Devart.Data.Linq.Engine.dr.f(Expression A_0)
at Devart.Data.Linq.Engine.DataQuery`1.h()