Gentlefolk,
I have a FireBird database table with 'integer' type field with a 'NULL' value.
When I load the table into a SQLQuery-DBGrid combination the field/cell is displayed as an 'empty' cell.
This is what I want as the user simply types data into an 'empty' cell in the DBGrid.
If I wish to delete data in the table field, that is reset the field in the database so that the DBGrid cell displays an 'empty' cell. how do I do it?
How do I write a 'NULL' into the table field?
The following code results in a 0 (zero) in the table field.
var
vVariant : Variant;
begin
InQ.Edit;
vVariant := NULL;
try
Variants.NullStrictConvert := False;
InQ.FieldByName('MemReg').AsInteger := vVariant;
finally
Variants.NullStrictConvert := True;
end;
end;
An help appreciated, Ian