Subject | Re: [IBO] Problems using IB_Query and IBOQuery |
---|---|
Author | Woody |
Post date | 2009-08-07T17:27:25Z |
From: "aztoquetti" <armandozt@...>
since it's a string and the field needs to compare to a string value, not a
numeric one.
Woody (TMW)
>Make sure you enclose the edit1.Text in additional quotes inside the SQL
> For example, if I have an EditBox, and I change its Text property to
> '12-3', and then I try to run the script...
>
> IB_Query1.Close;
> IB_Query1.SQL.Clear;
> IB_Query1.SQL.Add('Select * from DEPARTMENTS where ("Code" = '+ edit1.Text
> +')');
> IB_Query1.Open;
>
> ... when I try to run it, the following error message comes...
>
>
> Project Project1.exe raised exception class EIB_ISCERROR with message 'ISC
> ERROR CODE:335544334
> ISC ERROR MESSAGE:
> conversion error from string "12-3"
> '.Process stopped. Use Step or Run to continue.
since it's a string and the field needs to compare to a string value, not a
numeric one.
Woody (TMW)