jQuery in Action, 2nd edition*
The moose likes JDBC and the fly likes SQL question : changing the string size of a column Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "SQL question : changing the string size of a column" Watch "SQL question : changing the string size of a column" New topic
Author

SQL question : changing the string size of a column

Sam Zou
Ranch Hand

Joined: Nov 18, 2002
Posts: 40
Hi,
I have a table that is already created and filled with data. One of the column is a VARCHAR(20)
and I'd like to change it now to something bigger VARCHAR(300).
What is the SQL command to do it ??
Thanks


Sam<p>"Life is difficult"<br /> -Scott Peck-</p>
Leslie Chaim
Ranch Hand

Joined: May 22, 2002
Posts: 336
This is how it's done in Oracle:
alter table your_table modify the_column varchar2(300);


Normal is in the eye of the beholder
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SQL question : changing the string size of a column