I have a database with a date field named WeatherDate. I have a variable fgFieldName with the name of this field as its value. I want to find the maximum and minimum values, i.e., the earliest and latest dates, in the WeatherDate field. These formulas are not working correctly:
Both formulas are returning the WeatherDate value in the first row. Is there a way to get aggregate to work like this? (I know I can use an execute statement to work, but this would be nicer.)
So far, I have not gotten this to work. The aggregate formula is returning the value of the fgFieldName field in the active record, but does not find the min or max.