3 | | == Modules == |
4 | | creación de un catalogo de modules |
5 | | {{{ |
6 | | create table mms_d_module ( |
7 | | --//////////////////////////////////////////////////////////////////////////// |
8 | | co_module varchar unique not null, |
9 | | nu_version integer not null |
10 | | ); |
11 | | }}} |
12 | | ==== BASE ==== |
13 | | es el modulo imprecindible para los demas siguientes donde se difine las caracteristicas |
14 | | del objeto guardad0 |
15 | | |
16 | | ====== Script de tablas BASE versión 1 ====== |
17 | | |
18 | | {{{ |
19 | | |
20 | | insert into mms_d_module |
21 | | values ('BASE', 1); |
22 | | |
23 | | -- drop table mms_d_object; |
24 | | --//////////////////////////////////////////////////////////////////////////// |
25 | | create table mms_d_object ( |
26 | | --//////////////////////////////////////////////////////////////////////////// |
27 | | id_object serial unique not null, |
28 | | co_subclass varchar not null, |
29 | | co_name varchar not null, |
30 | | co_version varchar not null, |
31 | | ds_object varchar, |
32 | | ds_tags varchar, |
33 | | dt_creation timestamp not null, |
34 | | dt_modification timestamp not null, |
35 | | |
36 | | constraint PK01_mms_d_object |
37 | | primary key (id_object), |
38 | | |
39 | | constraint PK02_mms_d_object |
40 | | unique (co_subclass, co_name, co_version)); |
41 | | }}} |
42 | | |
43 | | |
44 | | ==== OZA ==== |
45 | | es el modulo del guardado de specificación del objeto ''objeto.oza'' |
46 | | |
47 | | ====== Script de tablas OZA versión 1 ====== |
48 | | |
49 | | {{{ |
50 | | |
51 | | insert into mms_d_module |
52 | | values ('OZA', 1); |
53 | | |
54 | | -- drop table mms_d_object_oza; |
55 | | --//////////////////////////////////////////////////////////////////////////// |
56 | | create table mms_d_object_oza ( |
57 | | --//////////////////////////////////////////////////////////////////////////// |
58 | | id_object integer not null, |
59 | | ob_oza varchar not null, |
60 | | |
61 | | constraint PK01_mms_d_object_oza |
62 | | primary key (id_object), |
63 | | |
64 | | constraint FK01_mms_d_object_oza |
65 | | foreign key (id_object) references mms_d_object(id_object) |
66 | | ); |
67 | | }}} |
| 4 | == Módulos == |
| 5 | |
| 6 | Previo a la creación de los distintos módulos se define un catálogo de módulos. |
| 7 | |
| 8 | Script SQL: [source:trunk/MmsDatabase/scripts/pgsql/master.sql master.sql]. |
| 9 | |
| 10 | === Base === |
| 11 | |
| 12 | Modulo imprecindible para los demás módulos donde se definen las caracteristicas del objeto guardado. |
| 13 | |
| 14 | Script SQL: |
| 15 | * Versión 1: [source:trunk/MmsDatabase/scripts/pgsql/base.1.sql base.1.sql]. |
| 16 | |
| 17 | === OZA === |
| 18 | |
| 19 | Modulo del guardado del objeto MMS ''objeto.oza''. |
| 20 | |
| 21 | Script SQL: |
| 22 | * Versión 1: [source:trunk/MmsDatabase/scripts/pgsql/oza.1.sql oza.1.sql]. |