Symbology data filtered by date

258
1
07-22-2021 09:56 AM
Babcock_Kristen_L
New Contributor III

I have a data set that has multiple sample points in the same location.  For an example, contaminants were collected at house A on 5 different dates.  I'm trying to show a symbology of Graduated colors to show the differences in the contaminants, but need the most recent date to show up first. How do I do this?  I don't see any locations to filter by date when I create my symbology.  Thanks for any help!!

0 Kudos
1 Reply
Eduardo_Fernandez_EsriAu
New Contributor II

Hello

For graduated colours, you can use an arcade expression to filter out features but this would be based on a comparison between dates rather than a "per house" (group by). Also the field type determines whether you can apply graduated colours tor not.

To order your attributes so that the most recent date shows first for each house, you would need to first use the Sort geoprocessing tool to define the house (id) field and date field to sort. This tool does create a new dataset. Alternatively, you could create a new database view and with some SQL code ( for example select house id, date, containment from feature class group by house id, date, containment order by date ascending). 

If the most recent date per house is the only feature you require to be represented on a map, then you can try a new layer with a definition query with SQL code that calculates max date, for example

<date> = (SELECT MAX(date) FROM <table_name> GROUP BY <house_ID>

Sort (Data Management)—ArcGIS Pro | Documentation

How To: Symbolize a range of dates using Arcade in ArcGIS Pro (esri.com)

How To: Select minimum and maximum values in the Select By Attributes window (esri.com)

Hope this helps 

Cheers Ed

 

 

 

0 Kudos