Vladimir Alexiev created JENA-1628:
--------------------------------------
Summary: apf:strSplit should take several possible separators
Key: JENA-1628
URL: https://issues.apache.org/jira/browse/JENA-1628
Project: Apache Jena
Issue Type: Improvement
Reporter: Vladimir Alexiev
We're working with some FP7 project data using tarql, and the column
"Participant Internet Homepage" sometimes as multiple values, separated by
- comma, semicolon, " / ", " or "
It would be nice if apf:strSplit took a regex delimiter (like perl's split),
then I could use it like this:
{noformat}
?websites apf:strSplit (?Participant_Internet_Homepage, "(,|;| / | or )")
{noformat}
If the change is considered breaking, a new function apf:strSplitByRegex can be
introduced.
For the time being, I'll try with this ugliness (should work, right?):
{noformat}
{?websites apf:strSplit (?Participant_Internet_Homepage, ",")} union
{?websites apf:strSplit (?Participant_Internet_Homepage, ";")} union
{?websites apf:strSplit (?Participant_Internet_Homepage, " / ")} union
{?websites apf:strSplit (?Participant_Internet_Homepage, " or ")}
{noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)