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 1,377 of 2,288   
   Jim Kennedy to Dylan Nicholson   
   Re: ALTER TABLE requires extra parenthes   
   06 May 04 02:22:24   
   
   XPost: comp.databases.oracle.misc, microsoft.public.data.odbc   
   From: kennedy-downwithspammersfamily@attbi.net   
      
   "Dylan Nicholson"  wrote in message   
   news:7d428a77.0405051726.10d5e1b2@posting.google.com...   
   > Seems that Oracle 9.2 (using MS ODBC driver) requires extra   
   > parentheses when adding multiple columns to a table:   
   >   
   > ALTER TABLE MyTable ADD (MyColumn1 VARCHAR(255), MyColumn2   
   > VARCHAR(255))   
   >   
   > vs   
   >   
   > ALTER TABLE MyTable ADD MyColumn1 VARCHAR(255), MyColumn2 VARCHAR(255)   
   >   
   > The former simply doesn't work with MS Access or SQL server.  I'm   
   > wondering what the SQL standard is, and whether there is a way (other   
   > than adding columns one at a time, which is surely inefficient for a   
   > table with existing data) of writing the statement to work with all 3   
   > types of database.   
   >   
   > TIA   
   >   
   > Dylan   
      
   The driver might be "editing" your sql statements for you.  Try a pass thru   
   query.  Also usually for variable characters in Oracle you should use   
   varchar2 not varchar.  The extra parens should be ignored in any database   
   since they are just a grouping mechanism.   
   Jim   
      
   --- 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