[JBoss JIRA] (TEIID-2861) Partitioned UNION query fails
by Tom Arnold (JIRA)
Tom Arnold created TEIID-2861:
---------------------------------
Summary: Partitioned UNION query fails
Key: TEIID-2861
URL: https://issues.jboss.org/browse/TEIID-2861
Project: Teiid
Issue Type: Bug
Components: Query Engine
Affects Versions: 8.6
Reporter: Tom Arnold
Assignee: Steven Hawkins
I have a query like this where FOO and BAR are two different Oracle databases.
select * from (
…
[View More] (select item_id, created_at, 'Foo' source from foo.items order by created_at desc limit 5000)
union all
(select item_id, created_at, 'Bar' source from bar.items order by created_at desc limit 5000)
) x
where
source in ('Foo', 'Bar')
order by created_at desc
limit 0, 500;
If I adjust the filter to only include results from the second query, I get an exception.
09:15:19,287 ERROR [org.teiid.PROCESSOR] (Worker5_QueryProcessorQueue50) 7rl0TEA59SdU TEIID30019 Unexpected exception for request 7rl0TEA59SdU.7: java.lang.ArrayIndexOutOfBoundsException: -1
at java.util.ArrayList.elementData(ArrayList.java:400) [rt.jar:1.7.0_51]
at java.util.ArrayList.get(ArrayList.java:413) [rt.jar:1.7.0_51]
at org.teiid.query.optimizer.relational.rules.RuleRaiseNull.raiseNullNode(RuleRaiseNull.java:170) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.query.optimizer.relational.rules.RuleRaiseNull.execute(RuleRaiseNull.java:70) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.query.optimizer.relational.RelationalPlanner.executeRules(RelationalPlanner.java:606) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.query.optimizer.relational.RelationalPlanner.optimize(RelationalPlanner.java:255) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.query.optimizer.QueryOptimizer.optimizePlan(QueryOptimizer.java:159) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:408) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.Request.processRequest(Request.java:435) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:600) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:309) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:248) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:273) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:214) [teiid-engine-8.6.0.Final.jar:8.6.0.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_51]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_51]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month
[JBoss JIRA] (TEIID-2859) Provide identity generation for TEXTTABLE and OBJECTTABLE
by Ramesh Reddy (JIRA)
[ https://issues.jboss.org/browse/TEIID-2859?page=com.atlassian.jira.plugin... ]
Ramesh Reddy updated TEIID-2859:
--------------------------------
Forum Reference: https://community.jboss.org/thread/237251
> Provide identity generation for TEXTTABLE and OBJECTTABLE
> ---------------------------------------------------------
>
> Key: TEIID-2859
> URL: https://issues.jboss.org/browse/TEIID-2859
> Project: Teiid
> …
[View More] Issue Type: Enhancement
> Components: Query Engine
> Reporter: Ramesh Reddy
> Assignee: Steven Hawkins
>
> Extend the functionality FOR ORDINALITY defined on XMLTABLE, to TEXTTABLE and OBJECTTABLE.
> This will useful in providing a automatic identity key if the data is being read from sources where there is identity column provided. The faced the issue when loading a text file like
> {code}
> VA,F,1910,Mary,848
> VA,F,1911,Mary,747
> {code}
> Where name each line is a separate row, but they do not have unique identifier attached with them. Also helpful with interfaces like OData where they require a PK on a table. This provides an easier alternative.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month
[JBoss JIRA] (TEIID-2859) Provide identity generation for TEXTTABLE and OBJECTTABLE
by Ramesh Reddy (JIRA)
Ramesh Reddy created TEIID-2859:
-----------------------------------
Summary: Provide identity generation for TEXTTABLE and OBJECTTABLE
Key: TEIID-2859
URL: https://issues.jboss.org/browse/TEIID-2859
Project: Teiid
Issue Type: Enhancement
Components: Query Engine
Reporter: Ramesh Reddy
Assignee: Steven Hawkins
Extend the functionality FOR ORDINALITY defined on XMLTABLE, to TEXTTABLE and …
[View More]OBJECTTABLE.
This will useful in providing a automatic identity key if the data is being read from sources where there is identity column provided. The faced the issue when loading a text file like
{code}
VA,F,1910,Mary,848
VA,F,1911,Mary,747
{code}
Where name each line is a separate row, but they do not have unique identifier attached with them. Also helpful with interfaces like OData where they require a PK on a table. This provides an easier alternative.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month
[JBoss JIRA] (TEIID-2857) Build Error with Teiid POM Dependency
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2857?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-2857:
----------------------------------
Assignee: Van Halbert (was: Steven Hawkins)
So Ivan the resolution here for 8.7 will be to use a pre-release, but probably not a SNAPSHOT, for the bom. I'm not sure however that we can generally guarantee that something like a bom reference we don't control will not be a snapshot.
You'll also have to use an expanding settings.xml file …
[View More](the developer setup page was corrected a while ago as it did reference a settings.xml that was not complete).
> Build Error with Teiid POM Dependency
> -------------------------------------
>
> Key: TEIID-2857
> URL: https://issues.jboss.org/browse/TEIID-2857
> Project: Teiid
> Issue Type: Bug
> Components: Embedded
> Affects Versions: 8.6
> Reporter: Ivan Chan
> Assignee: Van Halbert
> Labels: teiid
>
> In the jboss public maven repository:
> https://repository.jboss.org/nexus/content/groups/public
> The teiid-parent-8.6.0.Final.pom file has two dependencies which look to be
> Teiid build/configuration bugs.
> These two issues are causing our source code build to fail.
> The pom file is located here:
> https://repository.jboss.org/nexus/content/groups/public/org/jboss/teiid/...
> In this pom file there are two declared dependencies:
> <version.org.jboss.integration-platform>6.0.0-SNAPSHOT</version.org.jboss.integration-platform>
> <jbossas-version>7.2.0.Alpha1-redhat-4</jbossas-version>
> <dependency>
> <groupId>org.jboss.integration-platform</groupId>
> <artifactId>jboss-integration-platform-bom</artifactId>
> <version>${version.org.jboss.integration-platform}</version>
> <scope>import</scope>
> <type>pom</type>
> </dependency>
> <dependency>
> <groupId>org.jboss.as</groupId>
> <artifactId>jboss-as-parent</artifactId>
> <version>${jbossas-version}</version>
> <type>pom</type>
> <scope>import</scope>
> </dependency>
> Here are the issues:
> 1) Snapshot dependency existing in the 8.6.0-FINAL Release
> - jboss-integration-platform-bom/6.0.0-SNAPSHOT
> 2) Declared dependency does not exist in the repo repository.jboss.org
> - jboss-as-parent/7.2.0.Alpha1-redhat-4
> - We see dependencies only for:
> - 7.2.0.Alpha1-SNAPSHOT
> - 7.2.0.Fina
> I'm not sure why these dependencies are needed when pulling in the Teiid artifacts, but perhaps because the <scope> of
> these dependencies is set to "import" (<scope>import</scope>)
> Our usage of the repository.jboss.org is to have snapshots disabled. So that is why the 6.0.0-SNAPSHOT fails to be found.
> For the 7.2.0.Alpha1-redhat-4 dependency, it does not exist in
> repository.jboss.org so this also fails.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month
[JBoss JIRA] (TEIID-2858) Database use of char[>1] cause using Convert(x, x) and negates using an index
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2858?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-2858:
---------------------------------------
I still don't think we're on the same page. You'll need to be quite explicit as to what is happening. If you have a char[x] modeled as string, there should be no convert involved. Can you provide a scenario where this is happening?
Yes, Tom that is understood. As an aside we do now have limited support for function based indexes …
[View More]on internal materialized views.
> Database use of char[>1] cause using Convert(x,x) and negates using an index
> ----------------------------------------------------------------------------
>
> Key: TEIID-2858
> URL: https://issues.jboss.org/browse/TEIID-2858
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.4.1
> Reporter: Van Halbert
> Assignee: Steven Hawkins
>
> When a database defines a char of length greater than 1, a convert(x,x) is being used in the criteria, and thereby, negating the use of an index and causing table scans.
> Note: There is no option to change the database schemas, because they are from a COTS product.
> I would think there needs to be a solution in the translator such that if it can be detected that its for a char column and that it does not do the convert.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month
[JBoss JIRA] (TEIID-2858) Database use of char[>1] cause using Convert(x, x) and negates using an index
by Tom Johnston (JIRA)
[ https://issues.jboss.org/browse/TEIID-2858?page=com.atlassian.jira.plugin... ]
Tom Johnston commented on TEIID-2858:
-------------------------------------
As a general rule any function will negate the use of any index on the field. Though there are "function-based-indexes" these are not options with COTS products. Some consideration must be made when a potential fix has ramifications that would diminish the performance. "Middleware" already has something to prove when it comes to NOT …
[View More]heavily impacting performance so let's not purposely do something that can impact performance.
> Database use of char[>1] cause using Convert(x,x) and negates using an index
> ----------------------------------------------------------------------------
>
> Key: TEIID-2858
> URL: https://issues.jboss.org/browse/TEIID-2858
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.4.1
> Reporter: Van Halbert
> Assignee: Steven Hawkins
>
> When a database defines a char of length greater than 1, a convert(x,x) is being used in the criteria, and thereby, negating the use of an index and causing table scans.
> Note: There is no option to change the database schemas, because they are from a COTS product.
> I would think there needs to be a solution in the translator such that if it can be detected that its for a char column and that it does not do the convert.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[View Less]
11 years, 1 month