I'm working with an asset with data that consist of polylines and points. There are a lot of points that are created after work orders from field workers. These point have the same Uid as the specific Line segment. Relationship between line and point are One-to-Many. They are not necessarily intersecting. I would to add a field to the polyline attribute table to show total count of these points are matching with the line Uid.
Lines
| object Id | Uid |
|---|
| 1 | 731000 |
| 2 | 731001 |
| 3 | 731002 |
| 4 | 731003 |
| 5 | 722000 |
| 6 | 723000 |
Points
| object Id | date | Uid |
|---|
| 1 | 6/4/2020 | 731000 |
| 2 | 6/4/2020 | 731002 |
| 3 | 6/12/2020 | 731000 |
| 4 | 6/12/2020 | 731003 |
| 5 | 6/12/2020 | 722000 |
| 6 | 6/19/2020 | 731000 |
| 7 | 6/19/2020 | 731003 |
| 8 | 6/19/2020 | 722000 |
| 9 | 6/27/2020 | 731000 |
| 10 | 6/27/2020 | 722000 |
Goal:
| object Id | Uid | count |
|---|
| 1 | 731000 | 4 |
| 2 | 731001 | 0 |
| 3 | 731002 | 1 |
| 4 | 731003 | 2 |
| 5 | 722000 | 3 |
| 6 | 723000 | 0 |