Subject Stored Procedure Changed Params not used!!
Author ben_daniel81
Hi,

I'm an ibo newbie in the middle of converting some bde code to ibo.

I have a problem where a TIBOStoredProc will work the first time, but
anytime after that it will continue to use the param values it used
originally even though I have explicitly changed them.

Unpreparing the stored-proc before setting the values, and preparing
it after setting them doesn't help either.

I noticed that someone had the same problem in msg# 16519 but
unfortunately the thread ended with Helen Borrie dismissing this
problem entirely because she couldn't comprehend how one could
increment a generator in a stored procedure.

I'll use Uwe's example as I thought it was pretty clear:
Lets say I have a storedproc with 1 input param "AMOUNT" and 1 output
param "RESULT". The storedproc simply increments a generator using
gen_id by the value of AMOUNT and returns the value in the Result
param.

I am getting these results
AMOUNT=1,RESULT=1
AMOUNT=0,RESULT=2
AMOUNT=0,RESULT=3
AMOUNT=50,RESULT=4

When it should look like:
AMOUNT=1,RESULT=1
AMOUNT=0,RESULT=1
AMOUNT=0,RESULT=1
AMOUNT=50,RESULT=51

Has anyone found the fix to this problem?