I have the following query:
The getFee() UDF executes a procedure within a service program that performs several reads and calculations to determine a fee for an account. One of the tables that the procedure uses is "feetable". When I run this udf in the select statement of an sql that has a join to one of the tables used by the service program procedure, I get the following:
Is there something I'm supposed to specify in the function definition to avoid the record lock generated by the function call?
Code:
select table1.id, table2.name, feetable.feedesc, getFee(id) as fee from table1 inner join table2 on table1.id = table2.id inner join feetable on table1.foreignkey = feetable.key where somefield = somevalue ;
Code:
CPF5032 Record 123456 member FEETABLE already locked to this job.
Comment