You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@olingo.apache.org by Vinayak Joshi <wi...@gmail.com> on 2016/04/01 16:12:40 UTC

Is there a direct mapping for java.sql.Timestamp to an OData V4 /Olingo data type ?

Not sure if I am missing something, but I can't seem to find how I may map
my Java Timestamp values to a OData / Olingo type ? I see TimeOfDay and
Date, but neither combines Date and Time both.

How is this supposed to be handled - create my own complex type that splits
my java timestamp into a combination of Date + TimeOfDay + DateTimeOffset ?


Vin.

RE: Is there a direct mapping for java.sql.Timestamp to an OData V4 /Olingo data type ?

Posted by Erwan LETESSIER <Er...@ingenico.com>.
Hi here is how I property of type timestamp:

new CsdlProperty().setName("datetimeProperty").setType(EdmPrimitiveTypeKind.DateTimeOffset.getFullQualifiedName()).setPrecision(6)

Hope it helps

Erwan

De : Vinayak Joshi [mailto:winjoshi4@gmail.com]
Envoyé : vendredi 1 avril 2016 16:13
À : user@olingo.apache.org
Objet : Is there a direct mapping for java.sql.Timestamp to an OData V4 /Olingo data type ?

Not sure if I am missing something, but I can't seem to find how I may map my Java Timestamp values to a OData / Olingo type ? I see TimeOfDay and Date, but neither combines Date and Time both.

How is this supposed to be handled - create my own complex type that splits my java timestamp into a combination of Date + TimeOfDay + DateTimeOffset ?


Vin.
This email and its content belong to Ingenico Group. The enclosed information is confidential and may not be disclosed to any unauthorized person. If you have received it by mistake do not forward it and delete it from your system. Cet email et son contenu sont la propriété du Groupe Ingenico. L’information qu’il contient est confidentielle et ne peut être communiquée à des personnes non autorisées. Si vous l’avez reçu par erreur ne le transférez pas et supprimez-le.