mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-25 04:07:47 +00:00
README.md
This commit is contained in:
1 parent
1082cbf8dd
commit
267d63b60e
1 file changed
+2
-2
@@ -1021,7 +1021,7 @@ For example, avoid the table below:
|
||||
```sql
|
||||
CREATE TABLE persons (
|
||||
id INTEGER PRIMARY KEY,
|
||||
creationDate DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
creationDate DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, // Avoid
|
||||
...
|
||||
)
|
||||
```
|
||||
@@ -1031,7 +1031,7 @@ Instead, override `insert()` and provide the default value there:
|
||||
```sql
|
||||
CREATE TABLE persons (
|
||||
id INTEGER PRIMARY KEY,
|
||||
creationDate DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
creationDate DATETIME NOT NULL, // OK
|
||||
...
|
||||
)
|
||||
```
|
||||
|
||||
Reference in new issue
Block a user