You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "James Taylor (JIRA)" <ji...@apache.org> on 2015/04/30 08:54:07 UTC
[jira] [Reopened] (PHOENIX-1773) Backward compatibility for joins
fail after PHOENIX-1489
[ https://issues.apache.org/jira/browse/PHOENIX-1773?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
James Taylor reopened PHOENIX-1773:
-----------------------------------
Reopening for now, but waiting for [~mujtabachohan] to help us determine if/how to repro.
> Backward compatibility for joins fail after PHOENIX-1489
> --------------------------------------------------------
>
> Key: PHOENIX-1773
> URL: https://issues.apache.org/jira/browse/PHOENIX-1773
> Project: Phoenix
> Issue Type: Bug
> Affects Versions: 4.4.0
> Reporter: Mujtaba Chohan
> Assignee: Maryann Xue
> Fix For: 5.0.0, 4.4.0
>
> Attachments: PHOENIX-1773.patch
>
>
> With Phoenix 4.4 client/4.4 server execute the following:
> {code}
> CREATE TABLE T1 (PK1 CHAR(15) NOT NULL, PK2 CHAR(3) NOT NULL, PK3 CHAR(12) NOT NULL, C1 VARCHAR CONSTRAINT PK PRIMARY KEY(PK1, PK2, PK3)) MULTI_TENANT=true, SALT_BUCKETS=16;
> CREATE VIEW V1 (A1 VARCHAR, A2 VARCHAR, D1 DATE, D2 DATE) AS SELECT * FROM T1 WHERE PK2='AAA';
> CREATE VIEW V2 (B1 CHAR(12), B2 VARCHAR) AS SELECT * FROM T1 WHERE PK2='BBB';
> upsert into V1 values ('123xxxxxxxxxxx0','AAA','xxxxxxxxxxx0','C','S.','F',to_date('2010-01-12 14:59:26'),to_date('2025-03-31 14:59:26'));
> upsert into V2 values ('123xxxxxxxxxxx0','BBB','xxxxxxxxxxx0','T','xxxxxxxxxxx0','T');
> {code}
> With 4.4 client/4.4 server, 1 rows is returned (correct):
> {code}
> select * from V2 JOIN V1 on V2.B1 = V1.PK3;
> +-----------------+-----+--------------+------------------------------------------+--------------+---------------------------------+
> | PK1 | PK2 | PK3 | C1 | B1 | B2 |
> +-----------------+-----+--------------+------------------------------------------+--------------+---------------------------------+
> | 123xxxxxxxxxxx0 | BBB | xxxxxxxxxxx0 | T | xxxxxxxxxxx0 | T |
> +-----------------+-----+--------------+------------------------------------------+--------------+---------------------------------+
> {code}
> With Phoenix *v4.2.1 client*/4.4 server, no row is returned (incorrect):
> {code}
> select * from V2 JOIN V1 on V2.B1 = V1.PK3;
> +-----------------+--------+--------------+------------------------------------------+--------------+------------------------------+
> | V2.PK1 | V2.PK2 | V2.PK3 | V2.C1 | V2.B1 | V2.B2 |
> +-----------------+--------+--------------+------------------------------------------+--------------+------------------------------+
> +-----------------+--------+--------------+------------------------------------------+--------------+------------------------------+
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)