But my question was about the default parameter in the UDF.
Actually getData is having two parameters.
The first parameter is must,
and second will have a defult value.
And the problem got solved by using the keyword 'default'
-- '' will be considered as the value for second param
-- 'test' will be considered as the value for second param