Skip to content

sqlite does not support inserting default values #61

@donaldp

Description

@donaldp

formidablejs/framework version: 0.7.0

Details

knex throws a warning when using sqlite3 as the default database driver.

Expected Behavior

Warning shouldn't be thrown.

Actual Behavior

knex throws a warning when using sqlite3 as the default database driver.

Possible Fix

Add a knex config options in the database config so we can easily add the knex option to get rid of the warning when using sqlite.

Additional Info

Your Environment

  • Linux 5.11.0-40-generic
  • elementary OS 6 Odin (Ubuntu 20.04.3 LTS)
  • Node 14.18.1

Steps to Reproduce

  1. Open the .env file
  2. Set DB_CONNECTION to sqlite
  3. Create a sqlite file: touch database/db.sqlite
  4. Set DATABASE_URL to database/db.sqlite
  5. Cache the config: craftsman cache
  6. Run the application: npm run start:dev

Stack Trace

sqlite does not support inserting default values. Set the `useNullAsDefault` flag to hide this warning. (see docs http://knexjs.org/#Builder-insert).

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingenhancementNew feature or requesthelp wantedExtra attention is needed

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions