pwtools.sql.SQLiteDB.fill_column¶
- SQLiteDB.fill_column(col, values, start=1, extend=True, overwrite=False, table=None)[source]¶
Fill existing column col with values from values, starting from rowid start. “rowid” is a special sqlite column which is always present and which numbers all rows.
The column must already exist. To add a new column and fill it, see
attach_column()
.- Parameters:
col (str) – Column name.
values (sequence) – Values to be inserted.
start (int) – sqlite rowid value to start at (first row: start=1)
extend (bool) – If extend=True and len(values) extends the last row, then continue to add values. All other column entries will be NULL. If False, then we silently stop inserting at the last row.
overwrite (bool) – Whether to overwrite entries which are not NULL (None in Python).
table (str, optional)