mirror of
https://github.com/apache/impala.git
synced 2026-01-03 06:00:52 -05:00
Float/Doubles are lossy so using those as the default literal type is problematic. Change-Id: I5a619dd931d576e2e6cd7774139e9bafb9452db9 Reviewed-on: http://gerrit.ent.cloudera.com:8080/2758 Reviewed-by: Nong Li <nong@cloudera.com> Tested-by: jenkins
33 lines
633 B
Plaintext
33 lines
633 B
Plaintext
====
|
|
---- QUERY
|
|
values(1, 2+1, 1.0, 5.0 + 1.0, 'a')
|
|
---- RESULTS
|
|
1,3,1.0,6.0,'a'
|
|
---- TYPES
|
|
TINYINT, SMALLINT, DECIMAL, DECIMAL, STRING
|
|
====
|
|
---- QUERY
|
|
values(1+1, 2, 5.0, 'a') order by 1 limit 10
|
|
---- RESULTS
|
|
2,2,5.0,'a'
|
|
---- TYPES
|
|
SMALLINT, TINYINT, DECIMAL, STRING
|
|
====
|
|
---- QUERY
|
|
values((1+8, 2, 5.0, 'a'), (2, 3, 6.0, 'b'), (3, 4, 7.0, 'c'))
|
|
---- RESULTS
|
|
9,2,5.0,'a'
|
|
2,3,6.0,'b'
|
|
3,4,7.0,'c'
|
|
---- TYPES
|
|
SMALLINT, TINYINT, DECIMAL, STRING
|
|
====
|
|
---- QUERY
|
|
values((1+8, 2, 5.0, 'a'), (2, 3, 6.0, 'b'), (3, 4, 7.0, 'c')) order by 1 desc limit 2
|
|
---- RESULTS
|
|
9,2,5.0,'a'
|
|
3,4,7.0,'c'
|
|
---- TYPES
|
|
SMALLINT, TINYINT, DECIMAL, STRING
|
|
====
|