Home » RDBMS Server » Server Administration » Beginner SQL
Beginner SQL [message #373425] Mon, 16 April 2001 12:22 Go to next message
SGahlman
Messages: 2
Registered: April 2001
Junior Member
I am working with SQL7.0. I am working with multiple tables within a database.
What I want to do is modify/ create my own table with the specs from the already defined tables. HOWEVER- I want to modify the column size. Is this possible? If so, how?
Thanks for your patience...
Re: Beginner SQL [message #373426 is a reply to message #373425] Mon, 16 April 2001 13:39 Go to previous messageGo to next message
Don Tipton
Messages: 3
Registered: April 2001
Junior Member
Do you want to make the column larger or smaller?
Re: Beginner SQL [message #373427 is a reply to message #373426] Mon, 16 April 2001 13:45 Go to previous messageGo to next message
SGahlman
Messages: 2
Registered: April 2001
Junior Member
smaller
Re: Beginner SQL [message #373442 is a reply to message #373425] Tue, 17 April 2001 12:39 Go to previous messageGo to next message
Cindy
Messages: 88
Registered: November 1999
Member
Yes, it is possible, use the ALTER TABLE statement.

example:
ALTER TABLE dept30
MODIFY (ename VARCHAR2 (15));

Hope this help.
-- Cindy
Re: Beginner SQL [message #373574 is a reply to message #373427] Tue, 24 April 2001 05:34 Go to previous message
lp
Messages: 8
Registered: April 2001
Junior Member
if smaller, then the column should be empty, otherwise it will give error message as follows
"ORA-01441: column to be modified must be empty to decrease column length".
if larger, then no problem.
Previous Topic: Re: Ooopps! Replace Max with Min to retrieve correct result (-)
Next Topic: help with logic
Goto Forum:
  


Current Time: Sat Jun 29 00:11:11 CDT 2024