Select to view content in your preferred language

Query table for top 10 results

1758
3
Jump to solution
09-08-2020 07:17 AM
ChrisPopham
Emerging Contributor

I'm trying to automate map production with an ArcGIS Pro Layout, I need a table frame in the Layout to be of a predictable size/shape. They layer that will be displayed in the table is a series of points, essentially XYZ data. For consistency's sake, I just want to query and display the top 10-20 Z valued points in the table. I can't handpick the points, it needs to be scripted/automated. So far, I've not figured out a 'Top 20' query. (Arcade seems to have a 'TOP()' function but I can't make it work?!

Any Ideas???

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
KoryKramer
Esri Community Moderator

Have you looked into the Sort option? Add and modify table frames—ArcGIS Pro | Documentation 

If the table frame were set to show only 10 (or 20) records, the size of the frame shouldn't need to change, but if you point it at new data with the same schema, I would think that if you have Sort set up on a field, then the table in the layout would show the top 10 or 20 records.

View solution in original post

3 Replies
KoryKramer
Esri Community Moderator

Have you looked into the Sort option? Add and modify table frames—ArcGIS Pro | Documentation 

If the table frame were set to show only 10 (or 20) records, the size of the frame shouldn't need to change, but if you point it at new data with the same schema, I would think that if you have Sort set up on a field, then the table in the layout would show the top 10 or 20 records.

ChrisPopham
Emerging Contributor

That's exactly right, Kory, Thanks. I think I had it set to auto-scale the contents so it kept trying to cram every record into the table. Once I fixed the size of everything (and did the sort on my field) it sort of sneakily selects the top 20 (or whatever I give it room for). It's actually perfect! And much easier than I was trying to make it. Thanks so much! 

KoryKramer
Esri Community Moderator

Awesome.  Glad that works!

0 Kudos