[pal-cvs 2562] [294] updated pompei db shema

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2007年 7月 19日 (木) 03:01:22 JST


Revision: 294
          http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=pal&view=rev&rev=294
Author:   takeharu
Date:     2007-07-19 03:01:21 +0900 (Thu, 19 Jul 2007)

Log Message:
-----------
updated pompei db shema

Modified Paths:
--------------
    pompei/trunk/src/main/webapp/WEB-INF/db/create_table.sql


-------------- next part --------------
Modified: pompei/trunk/src/main/webapp/WEB-INF/db/create_table.sql
===================================================================
--- pompei/trunk/src/main/webapp/WEB-INF/db/create_table.sql	2007-07-18 18:00:16 UTC (rev 293)
+++ pompei/trunk/src/main/webapp/WEB-INF/db/create_table.sql	2007-07-18 18:01:21 UTC (rev 294)
@@ -53,7 +53,8 @@
 
 DROP TABLE categories;
 CREATE TABLE categories (
-   categories_id int NOT NULL,
+   categories_id int NOT NULL GENERATED ALWAYS AS IDENTITY
+	(START WITH 1, INCREMENT BY 1),
    categories_image varchar(64),
    parent_id int DEFAULT 0 NOT NULL,
    sort_order int,
@@ -69,6 +70,9 @@
    categories_name varchar(32) NOT NULL,
    PRIMARY KEY (categories_id, language_id)
 );
+ALTER TABLE categories_description
+  ADD FOREIGN KEY (categories_id)
+  REFERENCES categories (categories_id);
 
 DROP TABLE configuration;
 CREATE TABLE configuration (


pal-cvs メーリングリストの案内
Back to archive index