Page 1 of 1

Dynamic SQL Error SQL error code = -303 internal error

Posted: Fri 09 Aug 2013 15:10
by alexicum
Not informative Exception when procedure parameter type not the same like parameter type added at designtime or runtime.
(RU: Если тип параметра процедуры не соответствует типу параметра добавленного в runtime)

Code: Select all

create or alter procedure TEST_PARAMS_SP (
    ADATA varchar(16000))
as
begin
end

Code: Select all

procedure TForm1.btnTestParamsClick(Sender: TObject);
var
  p: TParam;
  b: TBytes;
begin
  q.SQLConnection.Open;
  q.SQL.Text := 'EXECUTE PROCEDURE TEST_PARAMS_SP(:ADATA)';
  q.Params.Clear;
  p := TParam.Create(q.Params);
  p.Name := 'ADATA';
  p.ParamType := ptInput;
  p.DataType := ftBlob;
  SetLength(b, 10);
  q.Params.ParamByName('ADATA').AsBlob := b;
  q.ExecSQL; // <<-- Exception
end;
Exception class EIBCError with message '
Dynamic SQL Error
SQL error code = -303
internal error'.

Firebird version: 2.1

Please fix Exception text.

Re: Dynamic SQL Error SQL error code = -303 internal error

Posted: Mon 12 Aug 2013 08:58
by AndreyZ
Thank you for the information. We have reproduced and fixed this problem. This fix will be included in the next dbExpress driver for InterBase and Firebird build.