[jira] [Updated] (IGNITE-21743) .NET: LINQ: Cast to decimal loses precision

2024-04-29 Thread Pavel Tupitsyn (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-21743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pavel Tupitsyn updated IGNITE-21743:

Priority: Minor  (was: Major)

> .NET: LINQ: Cast to decimal loses precision
> ---
>
> Key: IGNITE-21743
> URL: https://issues.apache.org/jira/browse/IGNITE-21743
> Project: Ignite
>  Issue Type: Bug
>  Components: platforms, thin client
>Affects Versions: 3.0.0-beta1
>Reporter: Pavel Tupitsyn
>Assignee: Pavel Tupitsyn
>Priority: Minor
>  Labels: .NET, LINQ, ignite-3
> Fix For: 3.0.0-beta2
>
>
> Currently we use *as decimal* cast, which results in *scale=0*, truncating 
> any digits after the decimal point.
> See ticket mention in *IgniteQueryExpressionVisitor* - we should specify 
> scale and precision when performing cast to decimal.
> Blocked by IGNITE-21745 : .NET can't read small values with high scale.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Updated] (IGNITE-21743) .NET: LINQ: Cast to decimal loses precision

2024-03-13 Thread Pavel Tupitsyn (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-21743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pavel Tupitsyn updated IGNITE-21743:

Description: 
Currently we use *as decimal* cast, which results in *scale=0*, truncating any 
digits after the decimal point.
See ticket mention in *IgniteQueryExpressionVisitor* - we should specify scale 
and precision when performing cast to decimal.

Blocked by IGNITE-21745 : .NET can't read small values with high scale.

  was:
Details TBD

{code}
else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
expression.Type) == typeof(decimal))
{
// Use max precision and scale when performing cast to achieve 
expected behavior.
// Otherwise, zero scale leads to rounding.
ResultBuilder.Append(" as decimal(20, 10))");
}
{code}

Blocked by IGNITE-21745 : .NET can't read small values with high scale.


> .NET: LINQ: Cast to decimal loses precision
> ---
>
> Key: IGNITE-21743
> URL: https://issues.apache.org/jira/browse/IGNITE-21743
> Project: Ignite
>  Issue Type: Bug
>  Components: platforms, thin client
>Affects Versions: 3.0.0-beta1
>Reporter: Pavel Tupitsyn
>Priority: Major
>  Labels: .NET, LINQ, ignite-3
> Fix For: 3.0.0-beta2
>
>
> Currently we use *as decimal* cast, which results in *scale=0*, truncating 
> any digits after the decimal point.
> See ticket mention in *IgniteQueryExpressionVisitor* - we should specify 
> scale and precision when performing cast to decimal.
> Blocked by IGNITE-21745 : .NET can't read small values with high scale.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Updated] (IGNITE-21743) .NET: LINQ: Cast to decimal loses precision

2024-03-13 Thread Pavel Tupitsyn (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-21743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pavel Tupitsyn updated IGNITE-21743:

Description: 
Details TBD

{code}
else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
expression.Type) == typeof(decimal))
{
// Use max precision and scale when performing cast to achieve 
expected behavior.
// Otherwise, zero scale leads to rounding.
ResultBuilder.Append(" as decimal(20, 10))");
}
{code}

Blocked by IGNITE-21745 : .NET can't read small values with high scale.

  was:
{code}
else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
expression.Type) == typeof(decimal))
{
// Use max precision and scale when performing cast to achieve 
expected behavior.
// Otherwise, zero scale leads to rounding.
ResultBuilder.Append(" as decimal(20, 10))");
}
{code}


> .NET: LINQ: Cast to decimal loses precision
> ---
>
> Key: IGNITE-21743
> URL: https://issues.apache.org/jira/browse/IGNITE-21743
> Project: Ignite
>  Issue Type: Bug
>  Components: platforms, thin client
>Affects Versions: 3.0.0-beta1
>Reporter: Pavel Tupitsyn
>Priority: Major
>  Labels: .NET, LINQ, ignite-3
> Fix For: 3.0.0-beta2
>
>
> Details TBD
> {code}
> else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
> expression.Type) == typeof(decimal))
> {
> // Use max precision and scale when performing cast to 
> achieve expected behavior.
> // Otherwise, zero scale leads to rounding.
> ResultBuilder.Append(" as decimal(20, 10))");
> }
> {code}
> Blocked by IGNITE-21745 : .NET can't read small values with high scale.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Updated] (IGNITE-21743) .NET: LINQ: Cast to decimal loses precision

2024-03-13 Thread Pavel Tupitsyn (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-21743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pavel Tupitsyn updated IGNITE-21743:

Description: 
{code}
else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
expression.Type) == typeof(decimal))
{
// Use max precision and scale when performing cast to achieve 
expected behavior.
// Otherwise, zero scale leads to rounding.
ResultBuilder.Append(" as decimal(20, 10))");
}
{code}

> .NET: LINQ: Cast to decimal loses precision
> ---
>
> Key: IGNITE-21743
> URL: https://issues.apache.org/jira/browse/IGNITE-21743
> Project: Ignite
>  Issue Type: Bug
>  Components: platforms, thin client
>Affects Versions: 3.0.0-beta1
>Reporter: Pavel Tupitsyn
>Priority: Major
>  Labels: .NET, LINQ, ignite-3
> Fix For: 3.0.0-beta2
>
>
> {code}
> else if ((Nullable.GetUnderlyingType(expression.Type) ?? 
> expression.Type) == typeof(decimal))
> {
> // Use max precision and scale when performing cast to 
> achieve expected behavior.
> // Otherwise, zero scale leads to rounding.
> ResultBuilder.Append(" as decimal(20, 10))");
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)