[solved] parambyname asstring error
Posted: 15.06.2012, 15:27
Hi,
I'm trying Zeos 7+delphi XE2+Firebird 1.5 and have a problem with parameters in query if is string, only de first character of string is received in firebird.
Example
Stored Procedure
begin
/* Procedure Text */
insert into TEST (VALOR, numero)
values (:VALOR, :numero);
texto=valor;
salida=numero;
suspend;
end
Query:
select *
from sp_test(:usr, :num)
ZQuery1.close;
ZQuery1.ParamByName('usr').AsString:='cfc';
ZQuery1.ParamByName('num').AsInteger:=9876;
ZQuery1.Open;
The query return:
c 9876
The field integer is correct, but the string is truncated.
Thankyou.
I'm trying Zeos 7+delphi XE2+Firebird 1.5 and have a problem with parameters in query if is string, only de first character of string is received in firebird.
Example
Stored Procedure
begin
/* Procedure Text */
insert into TEST (VALOR, numero)
values (:VALOR, :numero);
texto=valor;
salida=numero;
suspend;
end
Query:
select *
from sp_test(:usr, :num)
ZQuery1.close;
ZQuery1.ParamByName('usr').AsString:='cfc';
ZQuery1.ParamByName('num').AsInteger:=9876;
ZQuery1.Open;
The query return:
c 9876
The field integer is correct, but the string is truncated.
Thankyou.