You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafodion.apache.org by "Alice Chen (JIRA)" <ji...@apache.org> on 2015/07/22 20:15:12 UTC
[jira] [Created] (TRAFODION-201) LP Bug: 1295473 - Same query
returns different results when the column is a primary key
Alice Chen created TRAFODION-201:
------------------------------------
Summary: LP Bug: 1295473 - Same query returns different results when the column is a primary key
Key: TRAFODION-201
URL: https://issues.apache.org/jira/browse/TRAFODION-201
Project: Apache Trafodion
Issue Type: Bug
Components: sql-exe
Reporter: Weishiun Tsai
Assignee: Prashanth Vasudev
Priority: Critical
Same query returns different results on 2 tables with the same columns and the same data. The only difference is that one of the tables declares the column used in the query as a primary key. In the following output, the 1st part of the output shows that the query returns 3 rows when column a is not a primary key. The 2nd part of the output shows that the query returns only 2 rows when column a is declared as a primary key. Value 0, which should be returned, is not returned.
This is seen on the beta 0.7.0 RC1 build installed on a workstation.
-bash-4.1$ sqlci
Trafodion Conversational Interface 0.7.0
(c) Copyright 2014 Hewlett-Packard Development Company, LP.
>>create table minmax (a real not null);
--- SQL operation complete.
>>insert into minmax values (-10e10), (-1), (0), (1), (10e10);
--- 5 row(s) inserted.
>>select * from minmax where a < 10e-77;
A
---------------
-9.9999997E+010
-1.0000000E+000
0.0000000E+000
--- 3 row(s) selected.
>>drop table minmax;
================================================================================================
--- SQL operation complete.
>>create table minmax (a real not null, primary key(a));
--- SQL operation complete.
>>insert into minmax values (-10e10), (-1), (0), (1), (10e10);
--- 5 row(s) inserted.
>>select * from minmax where a < 10e-77;
A
---------------
-9.9999997E+010
-1.0000000E+000
--- 2 row(s) selected.
>>
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)