[JBoss JIRA] (TEIID-4614) statement executeOlapQuery quietly fails
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-4614?page=com.atlassian.jira.plugin... ]
Steven Hawkins closed TEIID-4614.
---------------------------------
> statement executeOlapQuery quietly fails
> ----------------------------------------
>
> Key: TEIID-4614
> URL: https://issues.jboss.org/browse/TEIID-4614
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 9.x, 8.7.9.6_2
> Reporter: Johnathon Lee
> Assignee: Steven Hawkins
>
> cellSet = stmt.executeOlapQuery(mdxQuery) in OlapQueryExecution is quietly failing.
> modify execute method to add Exception catch and printStackTrace
> {code:java}
> // Some comments here
> public void execute() throws TranslatorException {
> try {
> stmt = this.connection.createStatement();
> cellSet = stmt.executeOlapQuery(mdxQuery);
> CellSetAxis rowAxis = this.cellSet.getAxes().get(Axis.ROWS.axisOrdinal());
> rowPositionIterator = rowAxis.iterator();
> columnsAxis = cellSet.getAxes().get(Axis.COLUMNS.axisOrdinal());
> colWidth = rowAxis.getAxisMetaData().getHierarchies().size() + this.columnsAxis.getPositions().size();
> } catch (SQLException e) {
> throw new TranslatorException(e);
> } catch (Exception e) {
> e.printStackTrace();
> } finally {
> System.out.println("in finally block");
> }
> }
> {code}
> run existing tests to see (not catching the exception has all tests passing)
> {code:java}
> Running org.teiid.translator.olap.TestOlapTranslator
> org.teiid.core.TeiidRuntimeException
> at org.teiid.translator.olap.OlapQueryExecution.execute(OlapQueryExecution.java:100)
> at org.teiid.translator.olap.TestOlapTranslator.testCannedProcedure(TestOlapTranslator.java:67)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
> at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
> at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
> at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
> at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
> at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
> at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
> at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
> at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
> at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
> at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
> at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
> at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
> at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
> at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
> at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
> at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
> at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
> at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
> at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
> in finally block
> Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.541 sec <<< FAILURE! - in org.teiid.translator.olap.TestOlapTranslator
> testCannedProcedure(org.teiid.translator.olap.TestOlapTranslator) Time elapsed: 0.54 sec <<< FAILURE!
> java.lang.AssertionError: null
> at org.junit.Assert.fail(Assert.java:86)
> at org.junit.Assert.fail(Assert.java:95)
> at org.teiid.translator.olap.TestOlapTranslator.testCannedProcedure(TestOlapTranslator.java:68)
> Results :
> Failed tests:
> TestOlapTranslator.testCannedProcedure:68 null
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 4 months
[JBoss JIRA] (TEIID-4588) Duplicate column occurs when using translator to produce metadata for staging table
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-4588?page=com.atlassian.jira.plugin... ]
Steven Hawkins closed TEIID-4588.
---------------------------------
> Duplicate column occurs when using translator to produce metadata for staging table
> -----------------------------------------------------------------------------------
>
> Key: TEIID-4588
> URL: https://issues.jboss.org/browse/TEIID-4588
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.12.7.6_3, 9.2
> Reporter: Van Halbert
> Assignee: Van Halbert
> Priority: Blocker
> Fix For: 8.12.8.6_3, 9.2
>
>
> When deploying a VDB xml where the JDG source model doesn't contain the metadata, it relies upon the translator to generate the metadata for the tables. However, when there is a materialized view, the staging metadata is causing the following exception:
> {code}
> 19:52:29,254 ERROR [org.teiid.PROCESSOR] (Worker0_QueryProcessorQueue16) TEIID30019 Unexpected exception for request 7Dx4HhkSCh4e.0: java.lang.AssertionError: duplicate uid Column name=name, nameInSource=name, uuid=tid:97f8ad85a287-1c39ba6d-00000002
> at org.teiid.query.metadata.CompositeMetadataStore.addOid(CompositeMetadataStore.java:199) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.query.metadata.CompositeMetadataStore.addOids(CompositeMetadataStore.java:212) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.query.metadata.CompositeMetadataStore.assignOids(CompositeMetadataStore.java:179) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.query.metadata.CompositeMetadataStore.getOids(CompositeMetadataStore.java:231) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.dqp.internal.process.DataTierManagerImpl$13.processQuery(DataTierManagerImpl.java:567) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.dqp.internal.process.ChildRecordExtractionTable.processQuery(BaseExtractionTable.java:151) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.dqp.internal.process.DataTierManagerImpl.processSystemQuery(DataTierManagerImpl.java:1177) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> at org.teiid.dqp.internal.process.DataTierManagerImpl.registerRequest(DataTierManagerImpl.java:941) [teiid-engine-8.12.7.6_3-redhat-1.jar:8.12.7.6_3-redhat-1]
> {code}
>
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 4 months
[JBoss JIRA] (TEIID-4016) Teiid parser fails to address co-existence of SQL comment and cache hint prior to rest of SQL string
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-4016?page=com.atlassian.jira.plugin... ]
Steven Hawkins closed TEIID-4016.
---------------------------------
> Teiid parser fails to address co-existence of SQL comment and cache hint prior to rest of SQL string
> ----------------------------------------------------------------------------------------------------
>
> Key: TEIID-4016
> URL: https://issues.jboss.org/browse/TEIID-4016
> Project: Teiid
> Issue Type: Enhancement
> Components: Query Engine
> Affects Versions: 8.12.4
> Reporter: Paul Richardson
> Assignee: Steven Hawkins
> Fix For: 9.0, 8.12.5
>
>
> Please review analysis of the issue in TEIIDDES-2802.
> In summary, when a comment is located in front of the cache hint in an sql string, the cache hint is dropped from the resulting language objects. This is due to the regular expression used for finding cache hints in the parser template.
> For Designer to fix this issue, Teiid needs to fix it as well since the results of the parsers should match, ie. there is no point in Designer retaining the cache hint if Teiid does not.
> The following unit test demonstrates this issue:
> {code}
> String sql = "/* HELLO */ /*+ cache(ttl:180000) */ SELECT col1 FROM tbl WHERE col2 IN /*+ MJ */ (SELECT col1 FROM tbl2) /* trailing comment */ ";
> String expSql = "/*+ cache(ttl:180000) */ SELECT col1 FROM tbl WHERE col2 IN /*+ MJ */ (SELECT col1 FROM tbl2) /* trailing comment */ ";
> Command command = QueryParser.getQueryParser().parseCommand(sql, new ParseInfo());
> assertEquals(expSql, command.toString()); // this will fail due to no cache hint
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 4 months
[JBoss JIRA] (TEIID-3968) OData 4 array type handling
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-3968?page=com.atlassian.jira.plugin... ]
Steven Hawkins closed TEIID-3968.
---------------------------------
> OData 4 array type handling
> ---------------------------
>
> Key: TEIID-3968
> URL: https://issues.jboss.org/browse/TEIID-3968
> Project: Teiid
> Issue Type: Sub-task
> Components: OData
> Reporter: Steven Hawkins
> Assignee: Ramesh Reddy
> Fix For: 9.0, 8.12.5
>
>
> To ensure we are appropriate returning the correct error messages, creating the right upstream changes, etc. we have several paths to validate wrt array handling. There are:
> In the translator - ODataProcedureExecution.getQueryParameters, ODataFilterVisitor.visit(Function) and ODataFilterVisitor.visit(ColumnReference), ODataExpressionToSQLVisitor.visitAlias, ODataUpdateVisitor.visit(Update)
> In the OData service - ODataExpressionToSQLVisitor.visit(Alias)
> From the spec it appears that a uri should be able to specify arrays, but olingo and other frameworks may have limitations. For example it should be possible to have an array argument to a function, but the olingo framework will complain that arrays are not allowed in the resource part of the uri.
> At the very least we'll capture what won't work with this issue.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 4 months