Skip to content

Commit

Permalink
call_center: fix table versions in the DB schema
Browse files Browse the repository at this point in the history
(cherry picked from commit 3aa2034)
  • Loading branch information
rvlad-patrascu committed Nov 24, 2022
1 parent 37213d2 commit 6f65276
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion db/schema/cc_agents.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

<table id="cc_agents" xmlns:db="http://docbook.org/ns/docbook">
<name>cc_agents</name>
<version>2</version>
<version>3</version>
<type db="mysql">&MYSQL_TABLE_TYPE;</type>
<description>
<db:para>This table is used by the Call Center module to store
Expand Down
2 changes: 1 addition & 1 deletion db/schema/cc_flows.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

<table id="cc_flows" xmlns:db="http://docbook.org/ns/docbook">
<name>cc_flows</name>
<version>3</version>
<version>2</version>
<type db="mysql">&MYSQL_TABLE_TYPE;</type>
<description>
<db:para>This table is used by the Call Center module to store
Expand Down
4 changes: 2 additions & 2 deletions scripts/db_berkeley/opensips/version
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ carrierfailureroute|2
carrierroute|
carrierroute|3
cc_agents|
cc_agents|2
cc_agents|3
cc_calls|
cc_calls|3
cc_cdrs|
cc_cdrs|2
cc_flows|
cc_flows|3
cc_flows|2
closeddial|
closeddial|1
clusterer|
Expand Down
4 changes: 2 additions & 2 deletions scripts/dbtext/opensips/version
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ b2b_sca:1
cachedb:2
carrierfailureroute:2
carrierroute:3
cc_agents:2
cc_agents:3
cc_calls:3
cc_cdrs:2
cc_flows:3
cc_flows:2
closeddial:1
clusterer:4
cpl:2
Expand Down
4 changes: 2 additions & 2 deletions scripts/mysql/call_center-create.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
INSERT INTO version (table_name, table_version) values ('cc_flows','3');
INSERT INTO version (table_name, table_version) values ('cc_flows','2');
CREATE TABLE cc_flows (
id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL,
flowid CHAR(64) NOT NULL,
Expand All @@ -17,7 +17,7 @@ CREATE TABLE cc_flows (
CONSTRAINT unique_flowid UNIQUE (flowid)
) ENGINE=InnoDB;

INSERT INTO version (table_name, table_version) values ('cc_agents','2');
INSERT INTO version (table_name, table_version) values ('cc_agents','3');
CREATE TABLE cc_agents (
id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL,
agentid CHAR(128) NOT NULL,
Expand Down
4 changes: 2 additions & 2 deletions scripts/oracle/call_center-create.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
INSERT INTO version (table_name, table_version) values ('cc_flows','3');
INSERT INTO version (table_name, table_version) values ('cc_flows','2');
CREATE TABLE cc_flows (
id NUMBER(10) PRIMARY KEY,
flowid VARCHAR2(64),
Expand All @@ -25,7 +25,7 @@ END cc_flows_tr;
/
BEGIN map2users('cc_flows'); END;
/
INSERT INTO version (table_name, table_version) values ('cc_agents','2');
INSERT INTO version (table_name, table_version) values ('cc_agents','3');
CREATE TABLE cc_agents (
id NUMBER(10) PRIMARY KEY,
agentid VARCHAR2(128),
Expand Down
4 changes: 2 additions & 2 deletions scripts/postgres/call_center-create.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
INSERT INTO version (table_name, table_version) values ('cc_flows','3');
INSERT INTO version (table_name, table_version) values ('cc_flows','2');
CREATE TABLE cc_flows (
id SERIAL PRIMARY KEY NOT NULL,
flowid VARCHAR(64) NOT NULL,
Expand All @@ -18,7 +18,7 @@ CREATE TABLE cc_flows (
);

ALTER SEQUENCE cc_flows_id_seq MAXVALUE 2147483647 CYCLE;
INSERT INTO version (table_name, table_version) values ('cc_agents','2');
INSERT INTO version (table_name, table_version) values ('cc_agents','3');
CREATE TABLE cc_agents (
id SERIAL PRIMARY KEY NOT NULL,
agentid VARCHAR(128) NOT NULL,
Expand Down
4 changes: 2 additions & 2 deletions scripts/sqlite/call_center-create.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
INSERT INTO version (table_name, table_version) values ('cc_flows','3');
INSERT INTO version (table_name, table_version) values ('cc_flows','2');
CREATE TABLE cc_flows (
id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
flowid CHAR(64) NOT NULL,
Expand All @@ -17,7 +17,7 @@ CREATE TABLE cc_flows (
CONSTRAINT cc_flows_unique_flowid UNIQUE (flowid)
);

INSERT INTO version (table_name, table_version) values ('cc_agents','2');
INSERT INTO version (table_name, table_version) values ('cc_agents','3');
CREATE TABLE cc_agents (
id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
agentid CHAR(128) NOT NULL,
Expand Down

0 comments on commit 6f65276

Please sign in to comment.