From 633b42d4f030722142415145be11724f618bc7d0 Mon Sep 17 00:00:00 2001 From: lissav Date: Thu, 19 Aug 2010 11:40:51 +0000 Subject: [PATCH] add foreign key restrictions git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@7140 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/schema/samples/Sample.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xCAT-server/lib/xcat/schema/samples/Sample.pm b/xCAT-server/lib/xcat/schema/samples/Sample.pm index 398b303f7..41defe3ca 100644 --- a/xCAT-server/lib/xcat/schema/samples/Sample.pm +++ b/xCAT-server/lib/xcat/schema/samples/Sample.pm @@ -28,6 +28,7 @@ package xCAT_schema::Sample; # 8 Restart the the xcatd, the tables will be automatically generated. # 9 If you have service nodes, copy all the files to those also and restart # the daemon. +# # ############################################################################### %tabspec = ( @@ -50,7 +51,7 @@ package xCAT_schema::Sample; x_llnode => { cols => [qw(node jobid jobstatus cpu_usage comments disable)], keys => [qw(node)], - foreignkeys => [qw(("node") REFERENCES x_lljob("node") ON DELETE CASCADE)], # double quote are for db2, use backtics for mysql, noquotes for postgresal and sqlite + foreignkeys => [qw(("node") REFERENCES x_lljob("node") ON DELETE CASCADE)], # double quote are for db2, use backtics for mysql, noquotes for postgresal and sqlite. Tables with a Foreign key must not point to tables with a Foreign key or the tables may not be created in the correct order. Only one Foreign key per table is supported. required => [qw(node jobid)], types => { jobid => 'INTEGER',