Simon White
2018-08-01 13:34:56 UTC
Hi
I would like to suggest the addition of the "If not exists" to the Add
Column feature of SQLite. There are quite common situations where
ensuring a column exists is important so that an update to remote
devices will not fail but it is not so important that deprecated fields
be removed. This is often the case with backward compatibility. New
columns will not affect old systems but allows all remote devices
running older software to be updated using the same process as new
devices. Once the hardware reaches end of life it will be replaced and
the new hardware will use the new columns. So having the ability to
Alter the table with a series of Add Column commands ensures that the
new records included in the update are added to the table. These is
especially true for limited remote devices where full database
management is not feasible. In this scenario all that is required is
that the required columns exist. So to be able to alter the table with
a standard SQL command is the most efficient method on such devices.
Developing scripts to drop and re-create and re-load tables on hundreds
of remote devices greatly increases the risk of failures. Having the "if
not exists" would remove all of this potential complexity and allow a
quick and easy method to ensure the column exists in the table.
I would like to suggest the addition of the "If not exists" to the Add
Column feature of SQLite. There are quite common situations where
ensuring a column exists is important so that an update to remote
devices will not fail but it is not so important that deprecated fields
be removed. This is often the case with backward compatibility. New
columns will not affect old systems but allows all remote devices
running older software to be updated using the same process as new
devices. Once the hardware reaches end of life it will be replaced and
the new hardware will use the new columns. So having the ability to
Alter the table with a series of Add Column commands ensures that the
new records included in the update are added to the table. These is
especially true for limited remote devices where full database
management is not feasible. In this scenario all that is required is
that the required columns exist. So to be able to alter the table with
a standard SQL command is the most efficient method on such devices.
Developing scripts to drop and re-create and re-load tables on hundreds
of remote devices greatly increases the risk of failures. Having the "if
not exists" would remove all of this potential complexity and allow a
quick and easy method to ensure the column exists in the table.
--
Regards,
Simon White
dCipher Computing
705-500-0191
Regards,
Simon White
dCipher Computing
705-500-0191