I have a JSON map/dictionary where I want to find the largest value in it, but I’m having issues writing a UDF (using Legacy SQL syntax). I couldn’t find many resources or examples of this online, but I did see many for Standard SQL. Could anyone provide help or good online examples of dealing with maps, dictionaries, and user defined functions using Legacy SQL? Thanks!
Example input: {“cat_age”: 14, “dog_age”: 4} (this is a column in my table, let’s call the column name “AgeColumn”)
Output: 14