Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
New expression function sqlite_fetch_and_increment [FEATURE]
SQlite default values can only be applied on insert and not prefetched. This makes it impossible to acquire an incremented primary key via AUTO_INCREMENT before creating the row in the database. Sidenote: with postgres, this works via the option "evaluate default values". When adding new features with relations, it's really nice to be able to already add children for a parent, while the parents form is still open and hence the parent feature uncommitted. To get around this limitation, this function can be used to manage an incrementing value (or multiple sequences) in a separate table on sqlite based formats like gpkg.
- Loading branch information
Showing
1 changed file
with
122 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters