[SOLVED] Firebird 'Integer' field with NULL value lazarus / 16-Databases ---------------------------------------------------------------------- iru · 2015-03-08 22:43 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 ---------------------------------------------------------------------- balazsszekely · 2015-03-08 23:08 Hi Iru, Try this: InQ.FieldValues['MemReg'] := null; regards, GetMem ---------------------------------------------------------------------- iru · 2015-03-09 00:48 Thank you GetMem, fixed things nicely. Ian