[
https://issues.apache.org/jira/browse/OPENJPA-1465?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Milosz Tylenda reassigned OPENJPA-1465:
---------------------------------------
Assignee: (was: Milosz Tylenda)
> Queries over multi-valued elements within XML column
> ----------------------------------------------------
>
> Key: OPENJPA-1465
> URL: https://issues.apache.org/jira/browse/OPENJPA-1465
> Project: OpenJPA
> Issue Type: Improvement
> Components: query, sql
> Affects Versions: 1.2.1
> Reporter: Milosz Tylenda
>
> A request for query support over multi-valued elements within XML column has
> been posted on the user mailing list [1]. We currently support only queries
> over single-valued elements.
> I have investigated the matter a bit using MySQL. It seems that a query
> working correctly over multi-valued elements can be constructed like this
> ("street" is multi-valued):
> select * from TORDER t0 where
> ExtractValue(t0.shipAddress,'count(/*/street[text()="Lelevela"]) >= 1') = 1;
> or
> select * from TORDER t0 where
> ExtractValue(t0.shipAddress,'count(/*/street[text()="Lelevela"])') >= 1;
> What worries me is that such a query might not be indexable even if the
> database supports indexes over expressions.
> [1]
> http://n2.nabble.com/collection-valued-path-ArgumentException-when-querying-based-on-multi-valued-elements-in-an-XML-colun-tp4162113p4162113.html
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.