0

How should a date be formatted when using VQL (API)?

Good afternoon,

 

I am looking for a date example that I like to use in my .API.

Current VQL:
<value><![CDATA[type__v <> 'Document Change Control' and status__v contains ('Approved', 'Effective', 'Effective (Review Overdue)','Final','Superseded') and document_number__v like 'AMD-1310%' and version_modified_date__v > '2011-02-28' ]]></value>

Like a VQL:
<value><![CDATA[type__v <> 'Document Change Control' and status__v contains ('Approved', 'Effective', 'Effective (Review Overdue)','Final','Superseded') and document_number__v like 'AMD-1310%' and version_modified_date__v > 'Today Date - 2' ]]></value>

1 comment

  • Avatar
    Dan B

    When using Dates and DateTimes with VQL these should be formatted as YYYY-MM-DD and YYYY-MM-DD’T'HH:MM:SS.SSS'Z’. Please note these are stored in UTC (Coordinated Universal Time) and not the user’s time zone. Here are a couple links to our API documentation as well, discussing Date & Time Formats and Using Date & DateTime Values with VQL.

Please sign in to leave a comment.