Skip to content

Latest commit

 

History

History
67 lines (46 loc) · 1.82 KB

db.rst

File metadata and controls

67 lines (46 loc) · 1.82 KB

Database

Format: {scheme}://{user}:{password}@{host}:{port}/{database}?{parameters}

SQLite

SQLite accepts the following three formats:

  • in-memory database: sqlite://:memory:
  • relative path: sqlite:///db.sqlite3
  • absolute path: sqlite:////var/run/sqlite.db

Schemes

  • mysql: django.db.backends.mysql
  • oracle: django.db.backends.oracle
  • pgsql: django.db.backends.postgresql
  • postgres: django.db.backends.postgresql
  • postgresql: django.db.backends.postgresql
  • sqlite: django.db.backends.sqlite3
  • sqlite3: django.db.backends.sqlite3

Note

You can add more schemes with ~yaenv.db.add_scheme.

Parameters

You can define database options as query parameters.

Other parameters will be passed to OPTIONS as is.

See also

  • Env.db() <yaenv.core.Env.db>
  • db.parse() <yaenv.db.parse>