[JBoss JIRA] (TEIID-5353) Prepared Statement params are not pre-evaluated
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-5353?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration updated TEIID-5353:
-------------------------------------------
Bugzilla References: https://bugzilla.redhat.com/show_bug.cgi?id=1582521
Bugzilla Update: Perform
> Prepared Statement params are not pre-evaluated
> -----------------------------------------------
>
> Key: TEIID-5353
> URL: https://issues.jboss.org/browse/TEIID-5353
> Project: Teiid
> Issue Type: Bug
> Affects Versions: 8.12.12.6_4
> Reporter: Debbie Steigner
> Assignee: Steven Hawkins
>
> prepared statements, [1] with both criteria as parameters for the prepared statement, it appears that we are ignoring the SEARCH criteria because we are running both sides of the union. But for [2] if the SEARCH='FALSE' is in the query and not a param, we process as expected and only run the one side of the union.
> [1]
> sql = "select * from " +
> "Inventory_Detail" +
> " WHERE SEARCH = (?) and ITEM_ID in (?) OFFSET 0 ROWS FETCH NEXT 500 ROWS ONLY";
> PreparedStatement preparedStatement = conn.prepareStatement(sql);
> preparedStatement.setString(1,"FALSE");
> preparedStatement.setString(2,"1005014161091");
> ResultSet rs = null;
> [2]
> sql = "select * from " +
> "Inventory_Detail" +
> " WHERE SEARCH = 'FALSE' and ITEM_ID in (?) OFFSET 0 ROWS FETCH NEXT 500 ROWS ONLY";
> PreparedStatement preparedStatement = conn.prepareStatement(sql);
> preparedStatement.setString(1,"1005014161091");
> ResultSet rs = null;
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5353) Prepared Statement params are not pre-evaluated
by Debbie Steigner (JIRA)
Debbie Steigner created TEIID-5353:
--------------------------------------
Summary: Prepared Statement params are not pre-evaluated
Key: TEIID-5353
URL: https://issues.jboss.org/browse/TEIID-5353
Project: Teiid
Issue Type: Bug
Affects Versions: 8.12.12.6_4
Reporter: Debbie Steigner
Assignee: Steven Hawkins
prepared statements, [1] with both criteria as parameters for the prepared statement, it appears that we are ignoring the SEARCH criteria because we are running both sides of the union. But for [2] if the SEARCH='FALSE' is in the query and not a param, we process as expected and only run the one side of the union.
[1]
sql = "select * from " +
"Inventory_Detail" +
" WHERE SEARCH = (?) and ITEM_ID in (?) OFFSET 0 ROWS FETCH NEXT 500 ROWS ONLY";
PreparedStatement preparedStatement = conn.prepareStatement(sql);
preparedStatement.setString(1,"FALSE");
preparedStatement.setString(2,"1005014161091");
ResultSet rs = null;
[2]
sql = "select * from " +
"Inventory_Detail" +
" WHERE SEARCH = 'FALSE' and ITEM_ID in (?) OFFSET 0 ROWS FETCH NEXT 500 ROWS ONLY";
PreparedStatement preparedStatement = conn.prepareStatement(sql);
preparedStatement.setString(1,"1005014161091");
ResultSet rs = null;
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5349) JPA translator support for Enums
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5349?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-5349.
-----------------------------------
Resolution: Done
Thanks Harold that looks good. Merged and added to 10.3.x as well for the 10.3.2 release in about 4 weeks.
> JPA translator support for Enums
> --------------------------------
>
> Key: TEIID-5349
> URL: https://issues.jboss.org/browse/TEIID-5349
> Project: Teiid
> Issue Type: Enhancement
> Components: Misc. Connectors
> Reporter: Harold Campbell
> Assignee: Steven Hawkins
> Fix For: 11.0, 10.3.2
>
>
> The JPA translator does not currently support enums. Whenever it encounters one it throws a TranslatorException because an enum is neither a simpleType nor an entity/embeddable.
> It would be nice if the translator could support these mappings somehow.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5349) JPA translator support for Enums
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5349?page=com.atlassian.jira.plugin... ]
Steven Hawkins updated TEIID-5349:
----------------------------------
Issue Type: Enhancement (was: Feature Request)
Component/s: Misc. Connectors
Fix Version/s: 11.0
10.3.2
> JPA translator support for Enums
> --------------------------------
>
> Key: TEIID-5349
> URL: https://issues.jboss.org/browse/TEIID-5349
> Project: Teiid
> Issue Type: Enhancement
> Components: Misc. Connectors
> Reporter: Harold Campbell
> Assignee: Steven Hawkins
> Fix For: 11.0, 10.3.2
>
>
> The JPA translator does not currently support enums. Whenever it encounters one it throws a TranslatorException because an enum is neither a simpleType nor an entity/embeddable.
> It would be nice if the translator could support these mappings somehow.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5350) JPA translator vs de-typed entities
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5350?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-5350.
-----------------------------------
Fix Version/s: 10.3.2
Resolution: Done
Applied the pull request and put the change into 10.3.x as well.
> JPA translator vs de-typed entities
> -----------------------------------
>
> Key: TEIID-5350
> URL: https://issues.jboss.org/browse/TEIID-5350
> Project: Teiid
> Issue Type: Quality Risk
> Components: Misc. Connectors
> Reporter: Harold Campbell
> Assignee: Steven Hawkins
> Fix For: 11.0, 10.3.2
>
> Attachments: 0001-TEIID-5350-JPAMetadataProcessor-Ignore-entities-mana.patch
>
>
> See here for some background: https://hibernate.atlassian.net/browse/HHH-10968
> When the JPA translator encounters a de-typed entity, such as those synthesized by Hibernate Envers, a NullPointerException is thrown. This is because the entity getJavaType() returns null, and calling getName() on that goes boom.
> The simplest solution I can think of is to wrap the Metamodel in another one which filters out any entities/managed types which return null for getJavaType(), but if something more useful could be done with these things that would be nice.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5350) JPA translator vs de-typed entities
by Harold Campbell (JIRA)
[ https://issues.jboss.org/browse/TEIID-5350?page=com.atlassian.jira.plugin... ]
Harold Campbell commented on TEIID-5350:
----------------------------------------
Ah, great. Thanks!
> JPA translator vs de-typed entities
> -----------------------------------
>
> Key: TEIID-5350
> URL: https://issues.jboss.org/browse/TEIID-5350
> Project: Teiid
> Issue Type: Quality Risk
> Components: Misc. Connectors
> Reporter: Harold Campbell
> Assignee: Steven Hawkins
> Fix For: 11.0
>
> Attachments: 0001-TEIID-5350-JPAMetadataProcessor-Ignore-entities-mana.patch
>
>
> See here for some background: https://hibernate.atlassian.net/browse/HHH-10968
> When the JPA translator encounters a de-typed entity, such as those synthesized by Hibernate Envers, a NullPointerException is thrown. This is because the entity getJavaType() returns null, and calling getName() on that goes boom.
> The simplest solution I can think of is to wrap the Metamodel in another one which filters out any entities/managed types which return null for getJavaType(), but if something more useful could be done with these things that would be nice.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months
[JBoss JIRA] (TEIID-5350) JPA translator vs de-typed entities
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5350?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-5350:
---------------------------------------
No master is fine. We typically just back port from there.
> JPA translator vs de-typed entities
> -----------------------------------
>
> Key: TEIID-5350
> URL: https://issues.jboss.org/browse/TEIID-5350
> Project: Teiid
> Issue Type: Quality Risk
> Components: Misc. Connectors
> Reporter: Harold Campbell
> Assignee: Steven Hawkins
> Fix For: 11.0
>
> Attachments: 0001-TEIID-5350-JPAMetadataProcessor-Ignore-entities-mana.patch
>
>
> See here for some background: https://hibernate.atlassian.net/browse/HHH-10968
> When the JPA translator encounters a de-typed entity, such as those synthesized by Hibernate Envers, a NullPointerException is thrown. This is because the entity getJavaType() returns null, and calling getName() on that goes boom.
> The simplest solution I can think of is to wrap the Metamodel in another one which filters out any entities/managed types which return null for getJavaType(), but if something more useful could be done with these things that would be nice.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 6 months