Date format for DataService.query

What date format should I use when callig DataService.query method? This page contains examples like this: LastUpdated => ‘~>~ 2017-01-01 00:00:00’ ,but for some reason it doesn’t worr for me.

I do request:

<?xml version="1.0" encoding="UTF-8"?> DataService.query mycode Job 1000 0 StartDate ~<=~ 2018-03-20 00:00:00 JobTitle StartDate ContactId JobTitle 0

, but API returns data for 2017

You cannot change the last updated field. It can only be modified by the system.

I’m not trying to change it, I want to filter records by given period

Ah, gottcha. So I usually use the temporal format YmdTH:i:s

Thank you, it did the trick.

1 Like