>>>>Are you using
<<lcSql>>
inside TEXTMERGE?
>>>
>>>
>>>TEXT TO lcSql TEXTMERGE NOSHOW
>>> select * from udf_Function(<<parameter>>)
>>>ENDTEXT
>>>This.mExecuteSqlCommand(lcSql, 'curCursor', '')
>>>
>>
>>What is the exact code and the value of the 'parameter' in case when you get the errror?
>That's the exact code. Parameter value is an integer. But it might have a problem. So, why would it cause recursive problem?
Mark,
1) Replace parameter with m.parameter
2) You don't need text...endtext there
lcSQL = "select * from udf_Function("+trans(m.parameter)+")"
Cetin