Changes between Initial Version and Version 1 of Ticket #27061, comment 2
- Timestamp:
- Aug 14, 2016, 10:57:57 AM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #27061, comment 2
initial v1 3 3 There's no need for me to change the PostgreSQL installation or change the template encoding because I'm able to run the following CREATE statement in my environment setup: 4 4 5 {{{ 5 {{{#!sql 6 6 CREATE DATABASE <name> WITH TEMPLATE template0 ENCODING 'UTF8' 7 7 }}} … … 11 11 If Django could clone a test database from an existing database, that would be another option. It already has syntax like the following in postgresql's `_clone_test_db()` to clone a test database from another test database (from [https://github.com/django/django/blob/d7e0cf04b77c859d895e81ddb7af06a2ccfda5a7/django/db/backends/postgresql/creation.py#L26 here]: 12 12 13 {{{ 13 {{{#!python 14 14 cursor.execute("CREATE DATABASE %s WITH TEMPLATE %s" % ( 15 15 qn(target_database_name), qn(source_database_name)))