Pārlūkot izejas kodu

- pdt table added

Jan Janak 20 gadi atpakaļ
vecāks
revīzija
ce6f458eb1

+ 31 - 0
db/schema/pdt.xml

@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE table PUBLIC "-//iptel.org//DTD DBSchema V1.0//EN"
+  "http://iptel.org/dbschema/dtd/1.0/dbschema.dtd" [
+
+<!ENTITY % entities SYSTEM "entities.xml">
+%entities;
+
+]>
+
+<table>
+    <name>pdt</name>
+    <version>1</version>
+
+    <column id="pdt.prefix">
+	<name>prefix</name>
+	<type>string</type>
+	<size>32</size>
+    </column>
+
+    <column>
+	<name>domain</name>
+	<type>string</type>
+	<size>&uri_len;</size>
+    </column>
+
+    <index>
+	<name>pdt_idx</name>
+	<unique/>
+	<colref linkend="pdt.prefix"/>
+    </index>
+</table>

+ 2 - 0
db/schema/ser.xml

@@ -78,6 +78,8 @@
 
     <xi:include href="i18n.xml"/>
 
+    <xi:include href="pdt.xml"/>
+
     <!-- Include extra definitions if found, it is not
          an error if they are not present, although it
          would produce a warning

+ 4 - 0
db/schema/version.xml

@@ -119,4 +119,8 @@
 	<value col="tn"><xi:include href="i18n.xml" xpointer="xpointer(table/name/text())"/></value>
 	<value col="tv"><xi:include href="i18n.xml" xpointer="xpointer(table/version/text())"/></value>
     </row>
+    <row>
+	<value col="tn"><xi:include href="pdt.xml" xpointer="xpointer(table/name/text())"/></value>
+	<value col="tv"><xi:include href="pdt.xml" xpointer="xpointer(table/version/text())"/></value>
+    </row>
 </table>

+ 1 - 0
scripts/dbtext/ser_db/pdt

@@ -0,0 +1 @@
+prefix(str) domain(str) 

+ 1 - 0
scripts/dbtext/ser_db/tuple_notes

@@ -0,0 +1 @@
+presid(int) tupleid(str) note(str) lang(str) 

+ 2 - 2
scripts/dbtext/ser_db/version

@@ -16,11 +16,11 @@ trusted:1
 server_monitoring_agg:1
 speed_dial:2
 sd_attrs:1
-gw:2
+gw:3
 gw_grp:2
 lcr:1
 presentity:1
 presentity_contact:1
 watcherinfo:1
 i18n:1
-gw:2
+pdt:1

+ 8 - 2
scripts/mysql/my_create.sql

@@ -23,14 +23,14 @@ INSERT INTO version (table_name, table_version) VALUES ('trusted', '1');
 INSERT INTO version (table_name, table_version) VALUES ('server_monitoring_agg', '1');
 INSERT INTO version (table_name, table_version) VALUES ('speed_dial', '2');
 INSERT INTO version (table_name, table_version) VALUES ('sd_attrs', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('gw', '3');
 INSERT INTO version (table_name, table_version) VALUES ('gw_grp', '2');
 INSERT INTO version (table_name, table_version) VALUES ('lcr', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity_contact', '1');
 INSERT INTO version (table_name, table_version) VALUES ('watcherinfo', '1');
 INSERT INTO version (table_name, table_version) VALUES ('i18n', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('pdt', '1');
 
 CREATE TABLE acc (
     id INT AUTO_INCREMENT NOT NULL,
@@ -491,6 +491,12 @@ INSERT INTO i18n (code, lang, new_reason) VALUES ('603', 'cs_CZ.ascii', 'Odmitnu
 INSERT INTO i18n (code, lang, new_reason) VALUES ('604', 'cs_CZ.ascii', 'Neexistujici uzivatel nebo sluzba');
 INSERT INTO i18n (code, lang, new_reason) VALUES ('606', 'cs_CZ.ascii', 'Nelze akceptovat');
 
+CREATE TABLE pdt (
+    prefix VARCHAR(32) NOT NULL,
+    domain VARCHAR(255) NOT NULL,
+    UNIQUE KEY pdt_idx (prefix)
+);
+
 GRANT ALL ON ser.* TO 'ser'@'%' IDENTIFIED BY 'heslo';
 GRANT ALL ON ser.* TO 'ser'@'localhost' IDENTIFIED BY 'heslo';
 FLUSH PRIVILEGES;

+ 8 - 2
scripts/oracle/or_create.sql

@@ -20,14 +20,14 @@ INSERT INTO version (table_name, table_version) VALUES ('trusted', '1');
 INSERT INTO version (table_name, table_version) VALUES ('server_monitoring_agg', '1');
 INSERT INTO version (table_name, table_version) VALUES ('speed_dial', '2');
 INSERT INTO version (table_name, table_version) VALUES ('sd_attrs', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('gw', '3');
 INSERT INTO version (table_name, table_version) VALUES ('gw_grp', '2');
 INSERT INTO version (table_name, table_version) VALUES ('lcr', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity_contact', '1');
 INSERT INTO version (table_name, table_version) VALUES ('watcherinfo', '1');
 INSERT INTO version (table_name, table_version) VALUES ('i18n', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('pdt', '1');
 
 CREATE TABLE acc (
     id int NOT NULL,
@@ -473,3 +473,9 @@ INSERT INTO i18n (code, lang, new_reason) VALUES ('603', 'cs_CZ.ascii', 'Odmitnu
 INSERT INTO i18n (code, lang, new_reason) VALUES ('604', 'cs_CZ.ascii', 'Neexistujici uzivatel nebo sluzba');
 INSERT INTO i18n (code, lang, new_reason) VALUES ('606', 'cs_CZ.ascii', 'Nelze akceptovat');
 
+CREATE TABLE pdt (
+    prefix string(32) NOT NULL,
+    domain string(255) NOT NULL,
+    pdt_idx UNIQUE (prefix, )
+);
+

+ 8 - 2
scripts/postgres/pg_create.sql

@@ -20,14 +20,14 @@ INSERT INTO version (table_name, table_version) VALUES ('trusted', '1');
 INSERT INTO version (table_name, table_version) VALUES ('server_monitoring_agg', '1');
 INSERT INTO version (table_name, table_version) VALUES ('speed_dial', '2');
 INSERT INTO version (table_name, table_version) VALUES ('sd_attrs', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('gw', '3');
 INSERT INTO version (table_name, table_version) VALUES ('gw_grp', '2');
 INSERT INTO version (table_name, table_version) VALUES ('lcr', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity', '1');
 INSERT INTO version (table_name, table_version) VALUES ('presentity_contact', '1');
 INSERT INTO version (table_name, table_version) VALUES ('watcherinfo', '1');
 INSERT INTO version (table_name, table_version) VALUES ('i18n', '1');
-INSERT INTO version (table_name, table_version) VALUES ('gw', '2');
+INSERT INTO version (table_name, table_version) VALUES ('pdt', '1');
 
 CREATE TABLE acc (
     id SERIAL NOT NULL,
@@ -506,3 +506,9 @@ INSERT INTO i18n (code, lang, new_reason) VALUES ('603', 'cs_CZ.ascii', 'Odmitnu
 INSERT INTO i18n (code, lang, new_reason) VALUES ('604', 'cs_CZ.ascii', 'Neexistujici uzivatel nebo sluzba');
 INSERT INTO i18n (code, lang, new_reason) VALUES ('606', 'cs_CZ.ascii', 'Nelze akceptovat');
 
+CREATE TABLE pdt (
+    prefix VARCHAR(32) NOT NULL,
+    domain VARCHAR(255) NOT NULL,
+    CONSTRAINT pdt_idx UNIQUE (prefix)
+);
+