Subject Re: [IBO] Inserting a NULL value in a column
Author Helen Borrie
At 02:40 PM 08-09-02 -0700, you wrote:
>I am using Delphi Professional 4.0 with update pack 3
>and IB Objects version 4.2Gc. In a parameterized
>stored procedure, how do I insert a null value into a
>field that can accept a null value. Would the folowing
>code chunk do the trick.
>
>if (locAddr = '') then
>begin
> parameterByName('LOC_ADDRESS').isNull;
>end
>else
>begin
> parameterByName('LOC_ADDRESS').asString := locAddr;
>end;

if (locAddr = '') then
paramByName('LOC_ADDRESS').Clear;
else
paramByName('LOC_ADDRESS').asString := locAddr;

cheers,
Helen