Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Create users

Status
Not open for further replies.

nacho38

IS-IT--Management
Dec 16, 2002
34
US
Hello. I would like to know how to create users while in SQL plus? Is there a specific command to do this?

Thank you
 
Nacho,

Typical code to create a user parallels the following (replacing the &quot;< >&quot; entries with valid values, of course):

create user <username> identified by <password>
default tablespace <tablespace where you want this user's tables/indexes to reside when not otherwise specified>
temporary tablespace <name of tablespace for disk sorting>
quota <some number of bytes or megabytes or UNLIMITED> on <tablespace name>
/

Without quota on a tablespace, a user cannot create space-consuming objects such as tables and indexes.

In addition, you must GRANT the new user privileges to log-in and create space-consuming objects, thus:

GRANT <username> connect, resource;

The above two commands should allow <username> to log in and create objects. There are other code variations to achieve the same results, but these are typical.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA @ 20:46 (11Feb04) UTC (aka &quot;GMT&quot; and &quot;Zulu&quot;), 13:46 (11Feb04) Mountain Time)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top