Subject | Re: [firebird-support] Re: Use of params in where clause on 'BLOB SUB_TYPE 1' fields? |
---|---|
Author | Helen Borrie |
Post date | 2006-02-08T12:50:10Z |
At 10:51 PM 8/02/2006, you wrote:
a blob, you have to assign a blob to it. I'm sure if you explore the
FIB help, you'll find a method that enables this - typically (for a
text blob) passing the Lines object of a memo component to a stream
(SaveToStream) and then assigning the stream to your blob parameter.
It's a matter of convenience that the engine (in Fb 1.5 and higher)
will accept a *literal* string and convert it to a text blob for
you. A blob is a blob is a blob.
> > In what environment are you using the first syntax?Edit1.Text isn't a blob, it's a string. If you want to parameterise
>
>In the application we are building. I tried the same query in
>IBExpert and it won't work there either. We are using delphi with FIB
>datacomponents. But basically if i understood you correctly you can't
>pass a (string) parameter for a 'BLOB SUB_TYPE 1' field when
>using '=,<,>' operators in the where clause right ?
>
>Greetings,
>Filip Moons
>
>
> with AQuery do
> begin
> Transaction.StartTransaction;
> try
> ParamByName('ADESCRIPTION').AsString := Edit1.Text;
a blob, you have to assign a blob to it. I'm sure if you explore the
FIB help, you'll find a method that enables this - typically (for a
text blob) passing the Lines object of a memo component to a stream
(SaveToStream) and then assigning the stream to your blob parameter.
It's a matter of convenience that the engine (in Fb 1.5 and higher)
will accept a *literal* string and convert it to a text blob for
you. A blob is a blob is a blob.
> ExecQuery;Are you sure?
> finally
> if Open then
> Close;./heLen
> Transaction.Commit;
> end;
> end;