phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maryann Xue (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PHOENIX-1773) Backward compatibility for joins fail after PHOENIX-1489
Date Thu, 30 Apr 2015 00:39:06 GMT

    [ https://issues.apache.org/jira/browse/PHOENIX-1773?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14520620#comment-14520620
] 

Maryann Xue commented on PHOENIX-1773:
--------------------------------------

[~mujtabachohan] I did verify my patch locally before submitting it with the exact versions
and queries described here. So could you please check again or tell what versions would fail?

> 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)

Mime
View raw message