home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.databases.oracle      Overblown overpriced overengineered SHIT      2,288 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 725 of 2,288   
   mcstock to ponnurangam k   
   Re: Addition of constraint during creati   
   27 Nov 03 16:25:02   
   
   From: mcstockspamplug@spamdamenquery.com   
      
   reference the CREATE TABLE statement in the SQL manual for the 2 possible   
   syntaxes -- one of which is very similar to the alter table add constraint   
   syntax   
      
   also look into options such as DISABLED   
      
   also be ready for some strong opinions on whether you should include the   
   constraints in the CREATE TABLE   
      
   -- Mark Stock   
      
   "ponnurangam k"  wrote in message   
   news:d4c2c513.0311271151.bcfb931@posting.google.com...   
   | Hi All,   
   |   
   | I have few tables (abc, def) with with a specific structure and I need   
   | to add constratint to the table I do it with   
   |   
   | alter table abc   
   | add constraint abc_columnname_fk   
   | foreign key (columnname) references dec(columnname);   
   |   
   | But my question is how to create a table with this constraint embedded   
   | in the create table statement itself ? same, as in   
   |   
   | CREATE TABLE abc   
   | (columna PRIMARY KEY,   
   | Column2 CHAR(50) ???????????? );   
   |   
   | Can I embed the constraint during creation of the table only ?   
   |   
   | Can somebody please throw light or solution   
   |   
   | I am stuck with this problem.   
   |   
   | Thanks in advance,,   
   |   
   | PK   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca