[
https://issues.jboss.org/browse/TEIID-3671?page=com.atlassian.jira.plugin...
]
Juraj Duráni reopened TEIID-3671:
---------------------------------
The fix has been tested in 6.1.4. According to query, original issue is resolved \[1\].
However, Odata does not work because Teiid throws NPE \[2\].
\[1\]
6.1.2 --> /*+ cache(ttl:300000 scope:USER) */ SELECT g1.id_uk, g1.DISCOUNT, g1.type,
g1.PRICE, g1.ID FROM Source.sales AS g0 INNER JOIN Source.sales_uk AS g1 ON g0.ID = g1.ID
WHERE g1.DISCOUNT = ? ORDER BY g1.id_uk
6.1.4 --> /*+ cache(ttl:300000 scope:USER) */ SELECT g1.id_uk, g1.DISCOUNT, g1.type,
g1.PRICE, g1.ID FROM Source.sales AS g0 INNER JOIN Source.sales_uk AS g1 ON g0.ID = g1.ID
WHERE (g0.ID = '13') AND (g1.DISCOUNT = ?) ORDER BY g1.id_uk
\[2\]
{code:text}
10:43:15,485 WARN [org.teiid.ODATA] (http-/127.0.0.1:8180-3) TEIID16012 Could not produce
a successful OData response. Returning status ServerErrorException with message Internal
Server Error.: org.odata4j.exceptions.ServerErrorException
at org.teiid.odata.LocalClient.executeSQL(LocalClient.java:333) [classes:]
at org.teiid.odata.TeiidProducer.getNavProperty(TeiidProducer.java:89) [classes:]
at org.teiid.odata.TeiidProducer.getNavProperty(TeiidProducer.java:55) [classes:]
at
org.odata4j.producer.resources.PropertyRequestResource.getNavProperty(PropertyRequestResource.java:194)
[odata-core-0.8.7.redhat-61-1.jar:0.8.7.redhat-61-1]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_40]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[rt.jar:1.8.0_40]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[rt.jar:1.8.0_40]
at java.lang.reflect.Method.invoke(Method.java:497) [rt.jar:1.8.0_40]
at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:167)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:269)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:227)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.ResourceLocator.invokeOnTargetObject(ResourceLocator.java:159)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.ResourceLocator.invoke(ResourceLocator.java:92)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at
org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:542)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at
org.teiid.odata.ODataServletContainerDispatcher.service(ODataServletContainerDispatcher.java:118)
[classes:]
at org.teiid.odata.ODataServlet.service(ODataServlet.java:65) [classes:]
at
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)
[resteasy-jaxrs-2.3.8.SP4-redhat-2.jar:]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
[jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:512)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at
org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)
[jboss-as-web-7.4.3.Final-redhat-2.jar:7.4.3.Final-redhat-2]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926)
[jbossweb-7.4.10.Final-redhat-1.jar:7.4.10.Final-redhat-1]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_40]
Caused by: java.lang.NullPointerException
at org.teiid.odata.EntityList.getEntity(EntityList.java:62) [classes:]
at org.teiid.odata.EntityList.addEntity(EntityList.java:54) [classes:]
at org.teiid.odata.LocalClient.executeSQL(LocalClient.java:302) [classes:]
... 33 more
{code}
filter on child table not working
---------------------------------
Key: TEIID-3671
URL:
https://issues.jboss.org/browse/TEIID-3671
Project: Teiid
Issue Type: Bug
Components: OData
Reporter: Prashanthi Kairuppala
Assignee: Johnathon Lee
Priority: Critical
Fix For: 8.12, 8.11.4, 8.7.5
Attachments: parent_childTables.PNG
Please find the screenshot attached which has id as a foreign key. when i give the url -
//localhost:8080/odata/testVDB/sales('13')/sales_uk?$format=json, i get the
results from sales_uk table which are having id=13.
Now i am trying to apply a filter on this url, i am supposed to get results which are
having id=13 and satisfy the filter condition, but this url blindly returns me data from
sales_uk table which satisfy the filter condition. URL-
//localhost:8080/odata/testVDB/sales('13')/sales_uk?$format=json&$filter=DISCOUNT
eq '22'
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)