anonymous wrote : 
  | there are foreign key constraints between those tables (ie, the story table has a 
foreign key to the topic table)
  | 
Ok but I don't understand because in the script MySQL to create tables the forein keys 
are not declared (syntax 'FOREIGN KEY'). Why?
I think the foreign keys can't exist without this declaration !

Here the scripts :

CREATE TABLE nuke_topics (
  |                               pn_topicid TINYINT(4) NOT NULL AUTO_INCREMENT,
  |                               pn_topicname VARCHAR(255) DEFAULT NULL,
  |                               pn_topicimage VARCHAR(255) DEFAULT NULL,
  |                               pn_topictext VARCHAR(255) DEFAULT NULL,
  |                               pn_counter INT(11) NOT NULL DEFAULT '0',
  |                               PRIMARY KEY (pn_topicid)
  |                             ); 
  | 

CREATE TABLE nuke_stories (
  |                               pn_sid INT(11) NOT NULL AUTO_INCREMENT,
  |                               pn_state INT(11) NOT NULL DEFAULT '0',
  |                               pn_aid VARCHAR(30) NOT NULL DEFAULT '',
  |                               pn_title VARCHAR(255) DEFAULT NULL,
  |                               pn_time DATETIME DEFAULT NULL,
  |                               pn_hometext TEXT,
  |                               pn_bodytext TEXT NOT NULL,
  |                               pn_comments INT(11) DEFAULT '0',
  |                               pn_counter MEDIUMINT(8) UNSIGNED DEFAULT NULL,
  |                               pn_topic TINYINT(4) DEFAULT '1',
  |                               pn_informant VARCHAR(20) NOT NULL DEFAULT '',
  |                               pn_notes TEXT NOT NULL,
  |                               pn_ihome TINYINT(1) NOT NULL DEFAULT '0',
  |                               pn_themeoverride VARCHAR(30) NOT NULL DEFAULT '',
  |                               pn_language VARCHAR(30) NOT NULL DEFAULT '',
  |                               pn_withcomm TINYINT(1) NOT NULL DEFAULT '0',
  |                               pn_format_type TINYINT(1) UNSIGNED NOT NULL DEFAULT 
'0',
  |                               PRIMARY KEY  (pn_sid)
  |                             ); 
  | 

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3835542#3835542

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3835542


-------------------------------------------------------
This SF.Net email is sponsored by: SourceForge.net Broadband
Sign-up now for SourceForge Broadband and get the fastest
6.0/768 connection for only $19.95/mo for the first 3 months!
http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to