Skip to main content
New Participant
Dec 26, 2023 8:18 AM UTC
Question

Filter data hourly basis--how to construct Start Date Time & End Date Time

We have Modified on Date filed , which is Date Time.

Requirement is every hour scheduler runs and pick the data from now to past hour.

If the current date time is 26/12/2023 11:30 AM IST then Start Date Time =  26/12/2023 11:30 AM End Date Time  26/12/2023 10:30 AM.

Start Date Time I am calculating like =a!subtractDateTime(  startDateTime: now())

End Date Time: a!subtractDateTime(startDateTime: ac!startDateTime, hours: 1)

above 2 are giving me proper startDateTime and End Date Time. but when I pass to query Filter, I am using the <=Strat DateTime & >=End DateTime.

I have one record with Modified on is 26/12/2023 10:50 AM which is in between Start Date & End Date mentioned above. but still I am getting 0 Records from database.

How to construct Start  Time & End Date Time get hourly data. 

    2 replies

    swatig9469
    New Participant
    Dec 26, 2023 8:47 AM UTC

    Please check the time you are providing. The given end time is less than start time so the given criteria is wrong.

    konduruc733182
    Inspiring
    Dec 26, 2023 10:54 AM UTC

    Hello naveenm8768,

    Try configuring your start time as the initial time and your end time is your current time.

    Should be Between value<=Start Date Time =  26/12/2023 11:30 AM : >= End Date Time  26/12/2023 10:30 AM and I recommend using the between  instead.