Hoppa till huvudinnehållet

Query Layer: Get objects which were created the day before

Kommentarer

7 kommentarer

  • Nico Burgerhart

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

    https://enterprise.arcgis.com/en/server/latest/administer/windows/about-standardized-queries.htm

     

    1
  • 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.

    0
  • 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.

    0
  • 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

    1
  • 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.

    0
  • Yannik Bäder

    I don't have a solution yet.

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

     

    0

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