Select to view content in your preferred language

Cumulative count

789
2
Jump to solution
07-25-2018 07:46 AM
deleted-user-qpvAI3Fo0MKR
Deactivated User

I'm trying to create a cumulative count of IDs by Date in a field called Count.

For example, with these 3 IDs highlighted below, the results of Count would be 1, 2 and 3.

Any help would be greatly appreciated.

*edit - in the screenshot above the IDs have been sorted to be grouped.

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
DarrenWiens2
MVP Honored Contributor

See here for the logic behind tracking the count in a dictionary: https://community.esri.com/message/596160?commentID=596160#comment-596160 

And here for Update Cursor (ideally, your data is in a database and you can use ORDER_BY): UpdateCursor—Data Access module | ArcGIS Desktop 

View solution in original post

2 Replies
DarrenWiens2
MVP Honored Contributor

See here for the logic behind tracking the count in a dictionary: https://community.esri.com/message/596160?commentID=596160#comment-596160 

And here for Update Cursor (ideally, your data is in a database and you can use ORDER_BY): UpdateCursor—Data Access module | ArcGIS Desktop 

deleted-user-qpvAI3Fo0MKR
Deactivated User

Thanks you Darren Wiens‌ for providing the logic! I'm using the Sort tool to bring the .csv into scratch.gdb ready to be populated with the counts using your logic.

Many thanks again!

0 Kudos