Prefixes in query results?

Is it actually possible to receive query results containing prefixes rather than full URIs?

Assume I have data like

@prefix abc: .

abc:XYZ a owl:Thing .
abc:XYZ …

For any query, I’d like to get results in e.g. JSON that contain ‘abc:XYZ’ rather than ‘’. Is that somehow possible without own post-processing?


Hi Marcel,

Not really, the server returns full IRIs. However you can use some standard utilities, e.g. RDF4J’s JSONLDWriter, to print RDF in JSON in a compact form. Stardog 6 won’t use (and ship with) RDF4J but it will provide its own RDF writers for the same sort of purpose.


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.