On 29 Oct 2019, at 10:16pm, Warren Young <war...@etr-usa.com> wrote:

> One question I had after reading the draft doc is whether an 
> application-defined SQLITE_DETERMINISTIC function can be used to compute a 
> generated column.

Hmm.  Well, I can see that any non-deterministic function would be a problem 
here.  How about applying the logic from DEFAULT values and CHECK constraints ? 
 Do they allow deterministic functions ?

I just tried to find documentation to answer that but failed.

>>   ALTER TABLE ADD COLUMN cannot be used to add GENERATED ALWAYS … STORED 
>> columns
> 
> The doc should explain why this restriction exists, given that SQLite does 
> otherwise allow ALTER TABLE ADD COLUMN.

I believe that the developers don't want any ALTER TABLE command to have to 
rewrite all the data in the table.  I can see the reasoning.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to