You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by "McCann, Mike" <mc...@mbari.org> on 2003/05/28 18:28:32 UTC
DateTime query using OQL?
Hi,
I am using OGMG and would like to construct queries based on date-time select criteria, e.g.:
select d from foo.bar.Deployment where name="foobar" and startDate="Wed Dec 31 16:00:00 PST 1969"
However, the above does not work. The mapping for the startDate field (a java Date object) is:
<field-descriptor
name="startDate"
column="startDateTime"
jdbc-type="TIMESTAMP"
conversion="org.apache.ojb.broker.accesslayer.conversions.JavaDate2SqlTimestampFieldConversion"
/>
Can ODMG OQL perform selects based on date-time criteria? Should I be using another API to do this?
TIA,
Mike
--
Mike McCann (mccann@mbari.org)
Monterey Bay Aquarium Research Institute
7700 Sandholdt Road
Moss Landing, CA 95039-9644
Voice: (831) 775-1769 Fax: (831) 775-1646 http://www.mbari.org/rd/iag.htm