Activity Forums Salesforce® Discussions How you can use Datetime field as a criteria in SOQL Query?

  • Suraj

    Member
    April 27, 2017 at 6:22 am

    Hi Saurabh,

    We cannot use Datetime as condition in Where Clause in between single Quotes.

    You can do something like this ,

    WHERE CreatedDate > 2005-10-08T00:00:00Z

    Or, you can also use Date Literals like

    WHERE CreatedDate > YESTERDAY

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos