[ 
https://issues.apache.org/jira/browse/OLINGO-1147?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16102878#comment-16102878
 ] 

Archana Rai commented on OLINGO-1147:
-------------------------------------

This issue has been fixed as part of the commit: 
https://git-wip-us.apache.org/repos/asf?p=olingo-odata2.git;a=commit;h=6c7a67425af35bbaac7c4e9a7c0066d9a9463cc2

Thanks,
Archana

> Entity read is not working due to normalization in JPAQueryBuilder
> ------------------------------------------------------------------
>
>                 Key: OLINGO-1147
>                 URL: https://issues.apache.org/jira/browse/OLINGO-1147
>             Project: Olingo
>          Issue Type: Bug
>          Components: odata2-core
>    Affects Versions: V2 2.0.8
>            Reporter: Daniel Horvath
>            Priority: Blocker
>
> Hello Colleagues,
> We have found a bug in JPAQueryBuilder. In version 2.0.7 it is working fine 
> but in version 2.0.8 where the normalizeMembers() method is added it fails on 
> certain queries.
> The error happens in line 180: {color:red}return 
> em.createQuery(normalizeMembers(jpqlStatement.toString()));{color}
> The query before normalisation:
> *SELECT E1 FROM Entity E1 WHERE E1.id = 'ENTITY_NAME.1.2'*
> After the normalisation the query looks like this (an invalid query):
> *SELECT DISTINCT E1 FROM Entity E1 JOIN 'ENTITY_NAME.1 R1 WHERE E1.id = R1.2'*
> The regular expression finds this query as it should be normalised because of 
> the id part ('ENTITY_NAME.1.2'). As we found out, this is caused by the point 
> characters in the id field. It should not be found by the reg. exp. because 
> this is inside of apostrophes.
> If you have further questions, please contact me.
> Best regards,
> Daniel



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to