diff options
author | Kevin Harwell <kharwell@digium.com> | 2017-03-23 15:33:40 -0500 |
---|---|---|
committer | Kevin Harwell <kharwell@digium.com> | 2017-03-23 15:33:40 -0500 |
commit | 552cf009c0939c8b6597708135412bdc596df4bb (patch) | |
tree | cc461fe481f77ddf96063a0fec5b360541b05c86 /contrib/realtime/postgresql/postgresql_voicemail.sql | |
parent | f1b34e6eb465221902baf4dc9f8979201472202c (diff) |
Update for 13.15.0-rc113.15.0-rc1
Diffstat (limited to 'contrib/realtime/postgresql/postgresql_voicemail.sql')
-rw-r--r-- | contrib/realtime/postgresql/postgresql_voicemail.sql | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/contrib/realtime/postgresql/postgresql_voicemail.sql b/contrib/realtime/postgresql/postgresql_voicemail.sql new file mode 100644 index 000000000..f9257849c --- /dev/null +++ b/contrib/realtime/postgresql/postgresql_voicemail.sql @@ -0,0 +1,38 @@ +BEGIN; + +CREATE TABLE alembic_version ( + version_num VARCHAR(32) NOT NULL +); + +-- Running upgrade -> a2e9769475e + +CREATE TABLE voicemail_messages ( + dir VARCHAR(255) NOT NULL, + msgnum INTEGER NOT NULL, + context VARCHAR(80), + macrocontext VARCHAR(80), + callerid VARCHAR(80), + origtime INTEGER, + duration INTEGER, + recording BYTEA, + flag VARCHAR(30), + category VARCHAR(30), + mailboxuser VARCHAR(30), + mailboxcontext VARCHAR(30), + msg_id VARCHAR(40) +); + +ALTER TABLE voicemail_messages ADD CONSTRAINT voicemail_messages_dir_msgnum PRIMARY KEY (dir, msgnum); + +CREATE INDEX voicemail_messages_dir ON voicemail_messages (dir); + +INSERT INTO alembic_version (version_num) VALUES ('a2e9769475e'); + +-- Running upgrade a2e9769475e -> 39428242f7f5 + +ALTER TABLE voicemail_messages ALTER COLUMN recording TYPE BYTEA; + +UPDATE alembic_version SET version_num='39428242f7f5' WHERE alembic_version.version_num = 'a2e9769475e'; + +COMMIT; + |