Page 1 of 1

Problem with value assigment

Posted: Tue 29 Sep 2020 08:47
by EDrob
Hey,

we get following Error:
Incorrect values within SQLDA structure
empty pointer to data
at SQLVAR index 0


when running the following code

Code: Select all

     
     storedProc := TIBCStoredproc.Create(NIL);
      try
        storedProc.Transaction := IBCTransaction;
        storedProc.Connection  := connection;
        storedProc.StoredProcName := 'PROCNAME';
        storedProc.Prepare;
        storedProc.ParamByName('DateTimeVar').asString := DateTimeToStr(dateTimeValue);
        storedProc.ParamByName('IntegerVar').asInteger := -1;
        storedProc.ExecProc;
Problematic is the following Line:

Code: Select all

storedProc.ParamByName('DateTimeVar').asString := DateTimeToStr(dateTimeValue);
If we change the Line of Code as follow

Code: Select all

storedProc.ParamByName('DateTimeVar').asDateTime := dateTimeValue;
we won't get the SQLDA Error but the Procedure still doesn't get executed.
Only if we access the return value at least one time the SP get's executed.

We experience this behavior since upgrading from 7.2.X to 7.3.X.

Anyone experience this behavior as well?
Any help appreciated!

Regards
EDrob

Re: Problem with value assigment

Posted: Tue 29 Sep 2020 12:10
by oleg0k
Hello,

To solve the issue, please try to set the the DescribeParams option to True:
IBSStoredProc.Options.DescribeParams := True;

wbr, Oleg
Devart Team