Releases: obidea/semantika
Releases · obidea/semantika
1.7.1
Release Notes
This is a minor release for the upcoming 1.8. It contains some minor bug fixes and code improvement in the programming interface.
API Changes
- Method
ingetValueList()
QueryResult
is depreciated and got replaced bygetValueArray()
. - Class
Database
is able to give the current SQL dialect usinggetDialect()
method.
1.7
Release Notes:
- Improved Data Type Handling
There have been a lot of bug fixes for handling data types. Users can override data types and the system will ensure a safe conversion, including to addcast
function in SQL query automatically. The system support almost all primitive and derived XML datatypes (see table conversion below). However, data type reasoning is not available. - Support SPARQL STR
More support on SPARQL syntax. Users can use STR expression to get the string representation of a given literal in SPARQL query.
API Changes
- Class
Value
is no longer available. Iterating a value list will return you either aLiteral
orUri
object. Both are different classes to represent typed-value and object-value, respectively. - Use
getType()
to determine the type of aValue
object as an alternative way from usinginstanceof
condition. - When the JDBC Result Set returns
null
then the system produces anull
object as well in the value list. Therefore, you need to take carenull
object while iterating the value list, especially when dealing with queries that use OPTIONAL expression. - Class
QueryReturnMetadata
has been replaced byQueryMetadata
. The implementation is different especially the new class can determine the select item should be a literal-value or an object-value. DataTypeException
is a runtime exception. No need to try-and-catch it anymore.- The prefix manager has a
copy(Map<String,String>)
method to store prefix-namespace pairs in batch. XmlTypeToSqlType
defines type conversion XSD --> SQL in the following. (Note that the SQL types are represented by java.sql.Types constants.
XSD | SQL | XSD | SQL |
---|---|---|---|
xsd:string | Types.VARCHAR | xsd:unsignedByte | Types.SMALLINT |
xsd:boolean | Types.BOOLEAN | xsd:double | Types.DOUBLE |
xsd:decimal | Types.DECIMAL | xsd:float | Types.FLOAT |
xsd:long | Types.BIGINT | xsd:dateTime | Types.TIMESTAMP |
xsd:integer | Types.INTEGER | xsd:dateTimeStamp | Types.TIMESTAMP |
xsd:int | Types.INTEGER | xsd:date | Types.DATE |
xsd:short | Types.SMALLINT | xsd:time | Types.TIME |
xsd:byte | Types.TINYINT | xsd:gYearMonth | Types.VARCHAR |
xsd:nonNegativeInteger | Types.BIGINT | xsd:gMonthDay | Types.VARCHAR |
xsd:nonPositiveInteger | Types.BIGINT | xsd:gYear | Types.VARCHAR |
xsd:negativeInteger | Types.BIGINT | xsd:gMonth | Types.VARCHAR |
xsd:positiveInteger | Types.BIGINT | xsd:gDay | Types.VARCHAR |
xsd:unsignedLong | Types.BIGINT | ||
xsd:unsignedInt | Types.BIGINT | ||
xsd:unsignedShort | Types.INTEGER |
- Likewise,
SqlTypeToXmlType
defines type conversion SQL --> XSD in the following.
SQL | XSD | SQL | XSD |
---|---|---|---|
Types.NUMERIC | xsd:decimal | Types.NVARCHAR | xsd:string |
Types.DECIMAL | xsd:decimal | Types.LONGVARCHAR | xsd:string |
Types.BIGINT | xsd:long | Types.LONGNVARCHAR | xsd:string |
Types.INTEGER | xsd:integer | Types.DATE | xsd:date |
Types.SMALLINT | xsd:short | Types.TIME | xsd:time |
Types.TINYINT | xsd:byte | Types.TIMESTAMP | xsd:dateTime |
Types.REAL | xsd:float | Types.BOOLEAN | xsd:boolean |
Types.FLOAT | xsd:float | Types.BIT | xsd:boolean |
Types.DOUBLE | xsd:double | Types.OTHER | xsd:string |
Types.CHAR | xsd:string | ||
Types.VARCHAR | xsd:string | ||
Types.NCHAR | xsd:string |
Bug Fixes
[#11] Fix the incorrect value representation when the mapping term is specified as rr:IRI
.
[#12] The API should distinguish between literal-value and object-value (IRI-value).
1.6
Release Notes:
- Programmatic Configuration
Users can make configuration settings coded in Java program instead of using externalapplication.cfg.xml
file. It is useful to embed the settings entirely into the program without enclosing any revealing text. You can find the manual to use this in our wiki page - Support SPARQL LIMIT and OFFSET
More support on SPARQL syntax. Users can use these expressions to modify the query result based on the returned size (LIMIT) and/or the starting number of rows (OFFSET). - Improved TERMAL/XML
This is the native mapping language for Semantika, written in XML. The coding structure has been improved to follow better R2RML specification. This update makes both TERMAL/XML and R2RML format have a better compatibility in their semantic.