Scope of v_avg_salary
Just to clarify:
We 'call' a user-defined function by using the SELECT statement, followed by the function name, then its input/s enclosed with a pair of parenthesis.
However, when you run the query
SELECT v_avg_salary in 3:10, the error code 1054 only indicates that "You don't have a field/column named v_avg_salary", it doesn't say that "You use the function incorrectly". Is that right?