]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/sql/Pg/create_database_extensions.sql
LP#1564079 Checkout history skips nonexistent items
[Evergreen.git] / Open-ILS / src / sql / Pg / create_database_extensions.sql
1 -- This file is intended to be called by eg_db_config.pl
2
3 -- If manually calling:
4 -- Connect to the postgres database initially
5 -- Specify the database to create as -vdb_name=DATABASE
6 -- Specify the postgres contrib directory as -vcontrib_dir=CONTRIBDIR
7 -- You can get the contrib directory using pg_config --sharedir and adding a /contrib to it
8
9 -- NOTE: This file does not do transactions
10 -- This is intentional. Please do not wrap in BEGIN/COMMIT.
11 DROP DATABASE IF EXISTS :db_name;
12
13 CREATE DATABASE :db_name TEMPLATE template0 ENCODING 'UNICODE' LC_COLLATE 'C' LC_CTYPE 'C';
14
15 \connect :db_name
16
17 CREATE LANGUAGE plperlu;
18
19 CREATE EXTENSION tablefunc;
20 CREATE EXTENSION xml2;
21 CREATE EXTENSION hstore;
22 CREATE EXTENSION intarray;
23 CREATE EXTENSION pgcrypto;