<?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: Using runtime date fields as a query parameter in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/using-runtime-date-fields-as-a-query-parameter/m-p/25438#M289</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I also have spent a lot of time trying to figure this out. &amp;nbsp;I haven't tried your solution yet but it looks like it should work. &amp;nbsp;Exactly what I was looking for. (working on the Android side through) If someone from ESRI is looking at this a sample with a date query would be helpful &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/wink.png" /&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Jan 2017 19:22:35 GMT</pubDate>
    <dc:creator>ForrestKaye</dc:creator>
    <dc:date>2017-01-10T19:22:35Z</dc:date>
    <item>
      <title>Using runtime date fields as a query parameter</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/using-runtime-date-fields-as-a-query-parameter/m-p/25437#M288</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I was having trouble filtering data from a runtime geodatabase based on date fields (not using a time-aware database).&amp;nbsp; I finally figured it out:&lt;/P&gt;&lt;P&gt;&lt;A href="https://geobits.azurewebsites.net/querying-esri-runtime-database-featuretable-with-datetime-field/"&gt;https://geobits.azurewebsites.net/querying-esri-runtime-database-featuretable-with-datetime-field/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The quick-and-dirty version is that you need to do string comparisons of your date field and whatever NSDate variable you want to compare against, like this:&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b; padding-left: 60px;"&gt;&lt;SPAN style="color: #000000;"&gt;query.&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;whereClause&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; = [&lt;/SPAN&gt;&lt;SPAN style="color: #703daa;"&gt;NSString&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #3d1d81;"&gt;stringWithFormat&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;:&lt;/SPAN&gt;@"strftime('%%Y-%%m-%%d %%H:%%M:%%S', DateTime) &amp;gt;= '%@'"&lt;SPAN style="color: #000000;"&gt;, [&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;Utility&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #31595d;"&gt;returnStringFromDate&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;:mapViewController.&lt;/SPAN&gt;&lt;SPAN style="color: #4f8187;"&gt;filterDate&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #31595d;"&gt;withDateFormat&lt;/SPAN&gt;&lt;SPAN style="color: #000000;"&gt;:&lt;/SPAN&gt;@"yyyy-MM-dd 00:00:00 +0000"&lt;SPAN style="color: #000000;"&gt;]];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 11px; font-family: Menlo; color: #d12f1b; padding-left: 60px;"&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt; [Utility returnStringFromDate: withDateFormat:] is just a wrapper for an NSDateFormatter and string conversion function.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000;"&gt;-Mike&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Jan 2015 19:46:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/using-runtime-date-fields-as-a-query-parameter/m-p/25437#M288</guid>
      <dc:creator>MichaelDavis3</dc:creator>
      <dc:date>2015-01-29T19:46:56Z</dc:date>
    </item>
    <item>
      <title>Re: Using runtime date fields as a query parameter</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/using-runtime-date-fields-as-a-query-parameter/m-p/25438#M289</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I also have spent a lot of time trying to figure this out. &amp;nbsp;I haven't tried your solution yet but it looks like it should work. &amp;nbsp;Exactly what I was looking for. (working on the Android side through) If someone from ESRI is looking at this a sample with a date query would be helpful &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/wink.png" /&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jan 2017 19:22:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/using-runtime-date-fields-as-a-query-parameter/m-p/25438#M289</guid>
      <dc:creator>ForrestKaye</dc:creator>
      <dc:date>2017-01-10T19:22:35Z</dc:date>
    </item>
  </channel>
</rss>

