AnsweredAssumed Answered

AF Table lookup: finding the closest numeric value

Question asked by magnusst on May 20, 2016
Latest reply on May 24, 2016 by magnusst

Hello

 

I would like to do a lookup query to find the "closest" record based on matching a numeric attribute value with a number table value. In sql, I would do something like

SELECT TOP 1 * FROM [myTable] ORDER BY ABS( Area - @input )

 

But AF seem to not like the ABS() function in the WHERE clause of the lookup query.

 

Any suggestions to how I can get around this?

Outcomes