fixed crash if dynamic (columns) variables are used in UDF