<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Publishing Error with Definition query in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1561030#M90387</link>
    <description>&lt;P&gt;The thing is I have a script that reads the aprx file that has the FC in it and then uses that to overwrite the AGOL Feature Layer.&amp;nbsp; And it runs multiple times a day...&amp;nbsp;&lt;/P&gt;&lt;P&gt;The question is how does a software get to this point and something as simple as this does not work...typical esri... 3 steps to do one&lt;/P&gt;&lt;P&gt;I have to check the script again and maybe just run the original publishing with all the data and then modify the Python script to query the data and create a temp FC and use that to do the overwriting..&amp;nbsp;&lt;/P&gt;&lt;P&gt;so have a bit of work ahead...&lt;/P&gt;</description>
    <pubDate>Wed, 20 Nov 2024 23:16:25 GMT</pubDate>
    <dc:creator>kapalczynski</dc:creator>
    <dc:date>2024-11-20T23:16:25Z</dc:date>
    <item>
      <title>Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560442#M90337</link>
      <description>&lt;P&gt;I am getting an error when trying to publish am Oracle SDE Feature Class to AGOL.&amp;nbsp; It works in CASE 1 below but when I add the date it fails to publish..&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;NOTE:&amp;nbsp; It does not throw an error when I add the definition query.&amp;nbsp; In fact the definition query works fine as you can see from the image below.. there are over 700 records in this dataset and it is only showing 1.&amp;nbsp;&lt;/P&gt;&lt;P&gt;QUESTION: Why does it fail to publish with the date but does not throw an error in Pro&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CASE 1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;( PERMITSTATUS LIKE 'COMPLETED' OR PERMITSTATUS LIKE 'CANCELED' 
OR PERMITSTATUS LIKE 'DENIED' OR PERMITSTATUS LIKE 'Maintenance')&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CASE 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;(( PERMITSTATUS LIKE 'COMPLETED' OR PERMITSTATUS LIKE 'CANCELED' 
OR PERMITSTATUS LIKE 'DENIED' OR PERMITSTATUS LIKE 'Maintenance') 
AND PERMITCHANGEDATE &amp;gt;= ADD_MONTHS(TO_DATE(SYSDATE),-10))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="kapalczynski_0-1732046711913.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/119917iE5BF05D46DBE7BDC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="kapalczynski_0-1732046711913.png" alt="kapalczynski_0-1732046711913.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 20:12:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560442#M90337</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-19T20:12:39Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560450#M90338</link>
      <description>&lt;P&gt;Some oracle SQL may not function correctly in ArcGIS pro, even if it succeeds at a database level&lt;/P&gt;&lt;P&gt;Try using standard SQL, e.g.&lt;/P&gt;&lt;P&gt;(PERMITSTATUS IN ('COMPLETED', 'CANCELED', 'DENIED', 'Maintenance'))&amp;nbsp;&lt;/P&gt;&lt;P&gt;AND PERMITCHANGEDATE &amp;gt;= SYSDATE - INTERVAL '10' MONT&lt;SPAN&gt;H&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Similar discussion here&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://community.esri.com/t5/arcgis-pro-questions/definition-query-with-dates/td-p/1074642" target="_blank"&gt;https://community.esri.com/t5/arcgis-pro-questions/definition-query-with-dates/td-p/1074642&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 20:18:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560450#M90338</guid>
      <dc:creator>ChristopherCounsell</dc:creator>
      <dc:date>2024-11-19T20:18:13Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560462#M90341</link>
      <description>&lt;P&gt;hmmm failed again...&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="kapalczynski_0-1732048703141.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/119921iE32C0B8D6914B15F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="kapalczynski_0-1732048703141.png" alt="kapalczynski_0-1732048703141.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 20:38:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560462#M90341</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-19T20:38:42Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560466#M90342</link>
      <description>&lt;P&gt;Can you build it with the inbuilt ArcGIS pro query builder (not writing the SQL direct)?&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 20:40:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560466#M90342</guid>
      <dc:creator>ChristopherCounsell</dc:creator>
      <dc:date>2024-11-19T20:40:15Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560476#M90344</link>
      <description>&lt;P&gt;The below worked when I built it... looking at the SQL it created,,, but this does not look correct&amp;nbsp;&lt;/P&gt;&lt;P&gt;But not sure how to use NOW or SYSDATE and then minus 10 months&lt;BR /&gt;&lt;BR /&gt;PERMITSTATUS = 'COMPLETED' Or (PERMITSTATUS = 'CANCELED' And PERMITCHANGEDATE &amp;lt; TO_DATE('2023-05-01 15:52:58', 'YYYY-MM-DD HH24:MI:SS'))&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 20:57:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560476#M90344</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-19T20:57:03Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560481#M90347</link>
      <description>&lt;P&gt;This seemed to work... trying to publish now&lt;BR /&gt;&lt;BR /&gt;(PERMITSTATUS = 'COMPLETED' Or PERMITSTATUS = 'CANCELED' And PERMITCHANGEDATE &amp;lt; TO_DATE(SYSDATE - INTERVAL '10' MONTH, 'YYYY-MM-DD HH24:MI:SS'))&lt;/P&gt;&lt;P&gt;UPDATE:&amp;nbsp; no go on the publish... error again&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 21:02:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560481#M90347</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-19T21:02:40Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560508#M90349</link>
      <description>&lt;P&gt;Think I got it with this...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(( PERMITSTATUS LIKE 'COMPLETED' OR PERMITSTATUS LIKE 'CANCELED'&lt;/P&gt;&lt;P&gt;OR PERMITSTATUS LIKE 'DENIED' OR PERMITSTATUS LIKE 'Maintenance')&lt;/P&gt;&lt;P&gt;AND PERMITCHANGEDATE &amp;gt;(CURRENT_DATE - &lt;STRONG&gt;300&lt;/STRONG&gt;))&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2024 21:51:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560508#M90349</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-19T21:51:45Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560684#M90363</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/412943"&gt;@ChristopherCounsell&lt;/a&gt;&amp;nbsp; --- OK the above definition query worked in Pro.&amp;nbsp; It worked and gave NO errors on publishing... but when I go to AGOL and go to the data tab it says error and does not show data...&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I created another service and REMOVED the&amp;nbsp;&lt;SPAN&gt;AND PERMITCHANGEDATE &amp;gt;(CURRENT_DATE -&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;300&lt;/STRONG&gt;&lt;SPAN&gt;) and&lt;/SPAN&gt;&lt;SPAN&gt; everything worked...&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I then created another with ONLY the date and it works great.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;PERMITCHANGEDATE &amp;lt;= (CURRENT_DATE - 90) &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;BUT when I combine the 2 it breaks -- so it seems both work on their own but when I combine them it breaks&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;((PERMITSTATUS LIKE 'COMPLETED' OR PERMITSTATUS LIKE 'CANCELED' 
OR PERMITSTATUS LIKE 'DENIED' OR PERMITSTATUS LIKE 'Maintenance') 
AND PERMITCHANGEDATE &amp;lt;= (CURRENT_DATE - 90))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So it appears AGOL is still having issues with the combination of LIKE and DATE... &lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;If published individually they work great.&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;Errors are NOT thrown if they are combined and published to hosted Feature Layer,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Although AGOL errors when you try and look at the data. &lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="kapalczynski_0-1732108222200.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/119988iC78365F6BB783F2B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="kapalczynski_0-1732108222200.png" alt="kapalczynski_0-1732108222200.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Nov 2024 17:34:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1560684#M90363</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-20T17:34:07Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1561021#M90386</link>
      <description>&lt;P&gt;Given that you're publishing to ArcGIS online as a new layer&lt;/P&gt;&lt;P&gt;Can you export to a feature class first, then publish that layer (without the definition query)?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Nov 2024 21:55:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1561021#M90386</guid>
      <dc:creator>ChristopherCounsell</dc:creator>
      <dc:date>2024-11-20T21:55:36Z</dc:date>
    </item>
    <item>
      <title>Re: Publishing Error with Definition query</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1561030#M90387</link>
      <description>&lt;P&gt;The thing is I have a script that reads the aprx file that has the FC in it and then uses that to overwrite the AGOL Feature Layer.&amp;nbsp; And it runs multiple times a day...&amp;nbsp;&lt;/P&gt;&lt;P&gt;The question is how does a software get to this point and something as simple as this does not work...typical esri... 3 steps to do one&lt;/P&gt;&lt;P&gt;I have to check the script again and maybe just run the original publishing with all the data and then modify the Python script to query the data and create a temp FC and use that to do the overwriting..&amp;nbsp;&lt;/P&gt;&lt;P&gt;so have a bit of work ahead...&lt;/P&gt;</description>
      <pubDate>Wed, 20 Nov 2024 23:16:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/publishing-error-with-definition-query/m-p/1561030#M90387</guid>
      <dc:creator>kapalczynski</dc:creator>
      <dc:date>2024-11-20T23:16:25Z</dc:date>
    </item>
  </channel>
</rss>

