I'm using SQL-Server 6.5. In a table I've defined a foreign key on a field
which can be null. So if the user wants to break this relationship, I have
to enter a (null) value.
Maybe it is just me but i cannot find anything on giving a certain DB-field
the value : (Null).
thanks in advance,
Matthijs
--
======
please check mail-adress if replying by mail. I try to avoid SPAM.
>I'm using SQL-Server 6.5. In a table I've defined a foreign key on a field
>which can be null. So if the user wants to break this relationship, I have
>to enter a (null) value.
>Maybe it is just me but i cannot find anything on giving a certain DB-field
>the value : (Null).
Using methods of the VCL, call the TField.Clear method.
Query1.FieldByName('KeyField').Clear;
Using SQL, execute an UPDATE statement. In the SET clause, assign the
target column a value of NULL.
UPDATE YourTable
SET KeyField = NULL
WHERE (KeyField = "SomeValue")
//////////////////////////////////////////////////////////////////////////
Steve Koterski "The knowledge of the world is only to
Technical Publications be acquired in the world, and not in a
INPRISE Corporation closet."
http://www.inprise.com/delphi -- Earl of Chesterfield (1694-1773)