filak commented on issue #2974:
URL: https://github.com/apache/jena/issues/2974#issuecomment-2610426855
Thank you for quick reply. I have been able to get this working:
```
text:propLists (
[ text:propListProp mt:labelOnly ;
text:props (
rdfs:label
) ;
]
[ text:propListProp mt:noteOnly ;
text:props (
mt:note
) ;
]
[ text:propListProp mt:all ;
text:props (
rdfs:label
mt:note
) ;
]
) ;
.
<#entMap>
a text:EntityMap ;
# text:defaultField "ftext" ;
text:defaultField "labels" ;
text:entityField "uri" ;
text:uidField "uid" ;
text:langField "lang" ;
text:graphField "graph" ;
text:map (
# [ text:field "ftext" ; text:predicate rdfs:label ]
# [ text:field "ftext" ; text:predicate mt:note ]
[ text:field "labels" ; text:predicate rdfs:label ]
[ text:field "notes" ; text:predicate mt:note ]
) .
```
So there is no catch-all text:field - but this can be done by using mt:all
which seems to fit my use case.
select * where { (?s ?score) text:query (mt:all "beer OR grapes") } # 2
hits
The necessity to use the different text:field names should be emphasized in
the docs.
And maybe also that you cannot map a predicate multiple times to different
text:field - or that it has no effect (if i get it right that the following
queries do not work):
select * where { (?s ?score) text:query (mt:ftext "beer OR grapes") } #
0 hits
select * where { (?s ?score) text:query (text:ftext "beer OR grapes") }
# 0 hits
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]