Hoppa till huvudinnehållet

Query Layer: Get objects which were created the day before


7 kommentarer

  • Nico Burgerhart

    What is the setting for Standardized Queries on your ArcGIS Server? I could be the INTERVAL function is not allowed.



  • Yannik Bäder

    Hi Nico,

    thank you for the quick reply.

    Standardized Queries is set on true. But why don't occur errors in the REST-Service with the same where-clause?

    Is there an alternative to INTERVAL?

    Edit: I cannot change the property of Standardized Queries.

  • Yannik Bäder

    DATEFIELD = (CURRENT_DATE - 1) worked. But the DATEFIELD contains Hours, Minutes and Seconds. I didn'T find a way to properly convert datetime to date in order to compare the days.

    In Oracle I could use TRUNC() but ArcGIS Server won't allow this.

  • Berend Veldkamp

    You can't compare just the date, so you should be querying an interval, e.g. something like: DATEFIELD > (CURRENT_DATE - 1) AND DATEFIELD < CURRENT_DATE

  • Zack Robison

    I hate querying dates through Server.  It's like a box of chocolates in that you never know what you're gonna get.  It's not like a box of chocolates in that I actually like boxes of chocolates. 

    Yannik Bäder , please let us know when you figure out a solution so I can bookmark this for the next time I need to touch server with an Oracle backend.

  • Yannik Bäder

    I don't have a solution yet.

    By now I use this: DATEFIELD > (CURRENT_DATE - 2)



Du måste logga in om du vill lämna en kommentar.