function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
blabla 

Help With Event Query

Can anyone provide any insight on what is wrong with the following query:

select ActivityDate,WhoId,ActivityDateTime,AccountId,IsAllDayEvent,Description,CreatedDate,Subject,WhatId,Id from event where ActivityDateTime >= 2003-12-06T22:37:07.282Z-08:00 and ActivityDateTime
Whenever I run it I receive a MALFORMED_QUERY error.

Thanks..
adamgadamg

There is something funky going on with the time zone offset.

This works for me:

select ActivityDate,WhoId,ActivityDateTime,AccountId,IsAllDayEvent,Description,CreatedDate,Subject,WhatId,Id from event where ActivityDateTime >= 2003-12-05T12:37:00Z and ActivityDateTime <= 2003-12-06T12:37:00Z

But adding the time zone offset does not.  I'll look into it and let you know, but for now would recommending handling the time zone issues in your code and not the query.

blabla
Thanks.