data.world-py icon indicating copy to clipboard operation
data.world-py copied to clipboard

Support date/datetime and RDF types generally as query parameters

Open bryonjacob opened this issue 7 years ago • 1 comments

Support for more possible types as query parameters should be added.

date and datetime should map naturally to their XSD counterparts: https://docs.python.org/3/library/datetime.html

To give the developer complete capability to express values, add RdfLiteralParam which will have two parts value and type where value is a string and type is a URI - and which will render into "{value}"^^<{type}>. Existing code in the datadotworld.convert_to_sparql_literal should be refactored to use this class.

bryonjacob avatar Oct 09 '17 11:10 bryonjacob

For completeness it should support language as well, eg. "{value}"@{lang}.

Also, it looks to me like the current code doesn't escape special characters? https://github.com/datadotworld/dw-jdbc/blob/master/src/main/java/world/data/jdbc/internal/types/NTriplesFormat.java#L74-L109

shawnsmith avatar Oct 09 '17 14:10 shawnsmith