[JBoss JIRA] (TEIIDSB-186) Fix to use only use alias name from ExternalSource
by Ramesh Reddy (Jira)
[ https://issues.redhat.com/browse/TEIIDSB-186?focusedWorklogId=12450814&pa... ]
Ramesh Reddy logged work on TEIIDSB-186:
----------------------------------------
Author: Ramesh Reddy
Created on: 13/Apr/20 4:41 PM
Start Date: 13/Apr/20 4:41 PM
Worklog Time Spent: 3 days
Issue Time Tracking
-------------------
Remaining Estimate: 0 minutes
Time Spent: 3 days
Worklog Id: (was: 12450814)
> Fix to use only use alias name from ExternalSource
> --------------------------------------------------
>
> Key: TEIIDSB-186
> URL: https://issues.redhat.com/browse/TEIIDSB-186
> Project: Teiid Spring Boot
> Issue Type: Quality Risk
> Components: core
> Reporter: Ramesh Reddy
> Assignee: Ramesh Reddy
> Priority: Major
> Fix For: 1.5.0
>
> Time Spent: 3 days
> Remaining Estimate: 0 minutes
>
> As the code progressed the usage of translator name and alias name from ExternalSource class is interchangeably used. This is leading to confusion in terms of development and documents.
> Need to fix all the places where the translator name used to use alias name with Spring Boot engine.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 8 months
[JBoss JIRA] (TEIID-5933) Nested left joins return wrong results
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5933?focusedWorklogId=12450808&pag... ]
Steven Hawkins logged work on TEIID-5933:
-----------------------------------------
Author: Steven Hawkins
Created on: 10/Apr/20 3:43 PM
Start Date: 10/Apr/20 3:43 PM
Worklog Time Spent: 3 hours
Issue Time Tracking
-------------------
Remaining Estimate: 0 minutes (was: 3 hours)
Time Spent: 3 hours
Worklog Id: (was: 12450808)
> Nested left joins return wrong results
> --------------------------------------
>
> Key: TEIID-5933
> URL: https://issues.redhat.com/browse/TEIID-5933
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 3 hours
> Time Spent: 3 hours
> Remaining Estimate: 0 minutes
>
> Nested left joins in combination with a where x is null (on a left joined column) return wrong results:
> {code:sql}
> -- wrong result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
>
> -- correct result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> LIMIT 1000000000
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5933) Nested left joins return wrong results
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5933?page=com.atlassian.jira.plugi... ]
Steven Hawkins updated TEIID-5933:
----------------------------------
Original Estimate: 3 hours
Remaining Estimate: 3 hours
> Nested left joins return wrong results
> --------------------------------------
>
> Key: TEIID-5933
> URL: https://issues.redhat.com/browse/TEIID-5933
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 3 hours
> Remaining Estimate: 3 hours
>
> Nested left joins in combination with a where x is null (on a left joined column) return wrong results:
> {code:sql}
> -- wrong result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
>
> -- correct result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> LIMIT 1000000000
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5933) Nested left joins return wrong results
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5933?page=com.atlassian.jira.plugi... ]
Steven Hawkins updated TEIID-5933:
----------------------------------
Story Points: 0.5
Sprint: DV Sprint 62
> Nested left joins return wrong results
> --------------------------------------
>
> Key: TEIID-5933
> URL: https://issues.redhat.com/browse/TEIID-5933
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
>
> Nested left joins in combination with a where x is null (on a left joined column) return wrong results:
> {code:sql}
> -- wrong result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
>
> -- correct result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> LIMIT 1000000000
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5933) Nested left joins return wrong results
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5933?page=com.atlassian.jira.plugi... ]
Steven Hawkins resolved TEIID-5933.
-----------------------------------
Fix Version/s: 14.0
13.0.3
13.1.1
Resolution: Done
The check allowing the merging of the virtual layer under a left outer join was not looking if a nested predicate can return true on null values and thus cannot have it's position changed.
> Nested left joins return wrong results
> --------------------------------------
>
> Key: TEIID-5933
> URL: https://issues.redhat.com/browse/TEIID-5933
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
>
> Nested left joins in combination with a where x is null (on a left joined column) return wrong results:
> {code:sql}
> -- wrong result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
>
> -- correct result
> SELECT *
> FROM test_dwh_pg.test_1 a
> LEFT JOIN ( SELECT x.c1
> FROM test_dwh_pg.test_2 x
> LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
> LIMIT 1000000000
> ) b ON a.c1 = b.c1
> WHERE b.c1 IS NULL ;;
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5933) Nested left joins return wrong results
by Dmitrii Pogorelov (Jira)
Dmitrii Pogorelov created TEIID-5933:
----------------------------------------
Summary: Nested left joins return wrong results
Key: TEIID-5933
URL: https://issues.redhat.com/browse/TEIID-5933
Project: Teiid
Issue Type: Bug
Components: Query Engine
Affects Versions: 13.1
Reporter: Dmitrii Pogorelov
Assignee: Steven Hawkins
Nested left joins in combination with a where x is null (on a left joined column) return wrong results:
{code:sql}
-- wrong result
SELECT *
FROM test_dwh_pg.test_1 a
LEFT JOIN ( SELECT x.c1
FROM test_dwh_pg.test_2 x
LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
) b ON a.c1 = b.c1
WHERE b.c1 IS NULL ;;
-- correct result
SELECT *
FROM test_dwh_pg.test_1 a
LEFT JOIN ( SELECT x.c1
FROM test_dwh_pg.test_2 x
LEFT JOIN (SELECT * FROM test_dwh_pg.test_3 WHERE c1 <> '123') y ON x.c1 = y.c1 WHERE y.c1 IS NULL
LIMIT 1000000000
) b ON a.c1 = b.c1
WHERE b.c1 IS NULL ;;
{code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5932) HAVING in combination with LEFT JOIN of two XMLTABLE sub-queries returns an incorrect result
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5932?page=com.atlassian.jira.plugi... ]
Work on TEIID-5932 started by Steven Hawkins.
---------------------------------------------
> HAVING in combination with LEFT JOIN of two XMLTABLE sub-queries returns an incorrect result
> --------------------------------------------------------------------------------------------
>
> Key: TEIID-5932
> URL: https://issues.redhat.com/browse/TEIID-5932
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
>
> HAVING in combination with LEFT JOIN of two XMLTABLE sub-queries returns an incorrect result if one of XMLTABLE sub-queries has INNER, LEFT or CROSS JOIN instead of a lateral one and amount of rows in the source is equal or more than 1024. For example, the query:
> {code:sql}
> SELECT
> xt.event_id
> FROM test_dwh_pg.test_having AS d
> --here
> INNER JOIN XMLTABLE(
> '/root'
> PASSING JSONTOXML('root', d.str)
> COLUMNS
> event_id string PATH 'eventid'
> ) xt
> ON TRUE
> LEFT JOIN XMLTABLE(
> '/anything'
> PASSING JSONTOXML('anything', d.str)
> COLUMNS
> some_col string PATH 'anything'
> ) xt2
> ON xt.event_id = 'xxx'
> GROUP BY event_id
> HAVING COUNT(*) > 1 ;;
> {code}
> will return a result but it should return no results as there are no duplicates in test data.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months
[JBoss JIRA] (TEIID-5930) FULL JOIN missing data when not using LIMIT clause
by Dmitrii Pogorelov (Jira)
[ https://issues.redhat.com/browse/TEIID-5930?page=com.atlassian.jira.plugi... ]
Dmitrii Pogorelov commented on TEIID-5930:
------------------------------------------
[~shawkins] thx a lot for the quick fix, it worked!
> FULL JOIN missing data when not using LIMIT clause
> --------------------------------------------------
>
> Key: TEIID-5930
> URL: https://issues.redhat.com/browse/TEIID-5930
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 4 hours
> Time Spent: 3 hours
> Remaining Estimate: 1 hour
>
> When commenting out/uncommenting limit clause in the query:
> {code:sql}
> SELECT COUNT(*)
> FROM
> (
> SELECT
> date_value1
> , id
> FROM views.view1_m
> Limit 1000000000
> ) v1
> full
> JOIN
> (
> SELECT
> date_value2
> , id
> FROM views.view2_m
> LIMIT 1000000000
> ) v2
> ON
> v1.date_value1 = v2.date_value2
> and v1.id = v2.id ;;
> {code}
> teiid returns different results, for example, when using limits in all subqueries Teiid will return 3652, but when commenting out all limit clauses teiid in turn will return already 0.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
4 years, 9 months