Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Extending Tablespace
In article <369B52F8.F867EFD2_at_hotmail.com>,
ben dunlop <bkdunlop_at_hotmail.com> wrote:
> Hi All,
>
> How would I go about a simple method to extend a table space from the
> command line ?
>
> If anyone can assist in the syntax and methodology I would be very
> grateful.
>
> Regards
>
> Ben {the new user}
>
> Greetings, Ben,
Your question is a little vague...I assume you mean increasing the size of a tablespace's datafile, ie: your tablespace is allocated at, say, 20M, and you would like to make it 100M.
If you are running Oracle 7.3.4, you can do one of two things:
ALTER TABLESPACE tablespace_name ADD DATAFILE 'datafile_name' SIZE size_of_datafile, in K or M;
Example: I have a 20M tablespace called DATA1, the datafile is
called /oradata1/data1.dbf, and I want to add a 100M datafile. The database name is 'dev1'.
So: ALTER TABLESPACE DATA1 ADD DATAFILE '/oradata1/data2.dbf' size 100M;
2. In Oracle 7.3.4, you can resize a datafile. Using the previous example, you would execute the following command in either SQL*Plus or Server Manager:
ALTER DATABASE dev1 DATAFILE '/oradata1/data2.dbf' resize 120M;
Another option, if you have the Windows-based Oracle Client is to use the Oracle Storage Manager to change the size of the datafile. I think it's good to know how to use both the GUI-based and command-line based utilities, because you never know what you'll have in any given company.
I hope this helps. Best regards
-----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own Received on Tue Jan 12 1999 - 18:43:19 CST
![]() |
![]() |