dynamobi/dynamobi — Issue #819: [FRG-51] Cast -9223372036854775808 as string using java calc fails
Author: dynamobi-build
Created: 2011-12-30 03:50:41+00:00
State: open
Labels: FRG, Java Calc Codegen

[reporter="angel", created="Mon, 20 Feb 2006 18:13:11 -0500 (GMT-05:00)"]
Casting the minimum long, -9223372036854775808, to a string using the Java Calc fails, it is okay using the Fennel Calc.

Using the Java Calc (bad):

0: jdbc:farrago:> alter system set "calcVirtualMachine" = 'CALCVM_JAVA';

No rows affected (0.121 seconds)

0: jdbc:farrago:> values cast (-9223372036854775808 as varchar(30));

+-----------------------+

|EXPR$0 |

+-----------------------+

| -'..--).0-*(+,))+(0( |

+-----------------------+

1 row selected (0.757 seconds)

Using the Fennel Calc (okay):

0: jdbc:farrago:> alter system set "calcVirtualMachine" = 'CALCVM_FENNEL';

No rows affected (0.044 seconds)

0: jdbc:farrago:> values cast (-9223372036854775808 as varchar(30));

+-----------------------+

|EXPR$0 |

+-----------------------+

| -9223372036854775808 |

+-----------------------+

1 row selected (0.862 seconds)