AnsweredAssumed Answered

using date_to and date_from query filters

Question asked by mphelan on Nov 17, 2011
Latest reply on Feb 6, 2013 by riteshkumar
I am accessing a Data Source via the WSDL. On the WSDL side, the Data Source is made available under the Query subdirectory. I'm able to filter down the results of the query by using many of the different filter fields, but I'm having problems filtering on dates. Specifically, I need to be able to filter on a date, selecting only records where a particular date is less than the current date. I am finding that I can try many formats for the date, but I will get back zero results if I add any value for any date-based filter.

I notice that the date is defined as an xsd:DateTime under the complex type definition:
<xsd:element maxOccurs="1" minOccurs="1" name="start_date" type="xsd:dateTime" />
but that the filter items are defined as xsd:string type:
<xsd:element maxOccurs="1" minOccurs="0" name="start_date" type="xsd:string" /> 
<xsd:element maxOccurs="1" minOccurs="0" name="start_date_from" type="xsd:string" /> 
<xsd:element maxOccurs="1" minOccurs="0" name="start_date_to" type="xsd:string" /> 
<xsd:element maxOccurs="1" minOccurs="0" name="start_date_in" type="xsd:string" />
The original item in the back-end query is an Oracle DATE.

Does anyone have any idea of the proper format to use when filtering using the from, to, _in filters? So far, any use of the filter results in no records being returned.