Hi,
i need function like this, for example i have one data of location
when enter the second data, it calculates the distance between first data and second data, if it returns <100 M, it gives remarks "the distance < 100 m" for the second data
and then when enter the third data data, it check between 1st data and third data, is it < 100?
and also, it check between the second data and third data, is it < 100?
if any of them < 100, it return remarks "the distance < 100 m" in the third data,
and so the next data
This is not exactly what you asked for, but I think it will get you close to what you want:
COUNT(
SELECT(
table name[Row_ID],
DISTANCE([GeoTag], [_THISROW].[GeoTag]) * 1000 < 100
)
)-1& " event(s) within 100 meters"
I believe this will count the number of events within 100 meters of the rows [GeoTag] location compared to the full table. It then subtracts 1 to remove the comparison to itself. This then returns a value stating how many events are with 100 meters of that [GeoTag] value. I hope you can update this to get exactly what you need.
User | Count |
---|---|
17 | |
14 | |
10 | |
7 | |
4 |