Solved

how to do simplest create tablespace query

Posted on 2013-02-06
9
508 Views
Last Modified: 2013-02-06
This is gonna sound silly but I can't seem to get my create tablespace to work. Never done one before. Says I need a datafile?

I'm using a virtual box for queries to mess around but I want to know how to create tablespace for my user newuser

i tried "create tablespace newspace" after granting myself the create tablespace priv.

I want to know how to do the default, and a basic non-default version of create tablespace please
0
Comment
Question by:Mark_Co
  • 4
  • 3
  • 2
9 Comments
 
LVL 23

Accepted Solution

by:
David earned 250 total points
ID: 38860422
Here 'ya go!
http://docs.oracle.com/cd/B19306_01/server.102/b14200/statements_7003.htm

Your DBA must grant you the CREATE TABLESPACE role; then after it's created, the usual steps are to be granted QUOTA xx | UNLIMITED; create table(s) in that tablespace, etc.  Also, the O/S account used has to have write/execute permission on the datafile's directory or file system.
0
 

Author Comment

by:Mark_Co
ID: 38860500
so I don't need a datafile or path to give to the query like this example I saw on psoug?

CREATE TABLESPACE uwdata DATAFILE
'c:\oracle\oradata\orabase\uwdata01.dbf' SIZE 150M,
'c:\oracle\oradata\orabase\uwdata02.dbf' SIZE 100M
AUTOEXTEND OFF
BLOCKSIZE 8192
FORCE LOGGING
EXTENT MANAGEMENT LOCAL UNIFORM SIZE 256K
FLASHBACK ON;
0
 
LVL 76

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 250 total points
ID: 38860521
Check the doc link provided.

If you don't provide a full path, there is a default: DB_CREATE_FILE_DEST
0
 
LVL 23

Expert Comment

by:David
ID: 38860536
Unless I'm missing something obvious, which I do too often, the 2nd and 3rd rows provide the datafiles, fully pathed.  In case this is new, the tablespace is a logical component of the instance; the datafiles are physical -- so it's a mapping process between the two.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:Mark_Co
ID: 38860555
could not get this to work

CREATE TABLESPACE my_demo_space DATAFILE
'/data/ts_mydemo01.dbf' SIZE 1M
logging
ONLINE;
0
 

Author Comment

by:Mark_Co
ID: 38860606
"grant unlimited tablespace to newconnection"  did work
0
 
LVL 76

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 250 total points
ID: 38860608
>>could not get this to work

Error messages would be nice.

I assume you have a /data folder and oracle has read/write access to it?
0
 
LVL 23

Assisted Solution

by:David
David earned 250 total points
ID: 38860655
Your second example shifted from a Windows file format to a UNIX one.  Which OS did you mean?
0
 

Author Comment

by:Mark_Co
ID: 38860755
pardon, I'm running in a virtual machine which is linux
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Article by: Swadhin
From the Oracle SQL Reference (http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/queries006.htm) we are told that a join is a query that combines rows from two or more tables, views, or materialized views. This article provides a glimps…
Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now