How can I create a new database ?

How can I create a new database ?

Post by Theo Klei » Tue, 02 Apr 2002 04:11:26



During installation of Oracle 9i I created the database
databas1.Then I logged in as system/manager in SQL*Plus.Now I wanted to
create a new database with
"create database databas2;".
But I get error messages:
(I've translated my German messages to English, could be
the messages are not exactly like in the English version:)

Error in line one:
ORA-01501: CREATE DATABASE not successfull
ORA-01100: Database was connected with MOUNT
already

What's wrong ?

Theo Klein

 
 
 

How can I create a new database ?

Post by Kenneth C Stah » Tue, 02 Apr 2002 05:05:41



> During installation of Oracle 9i I created the database
> databas1.Then I logged in as system/manager in SQL*Plus.Now I wanted to
> create a new database with
> "create database databas2;".
> But I get error messages:
> (I've translated my German messages to English, could be
> the messages are not exactly like in the English version:)

> Error in line one:
> ORA-01501: CREATE DATABASE not successfull
> ORA-01100: Database was connected with MOUNT
> already

> What's wrong ?

> Theo Klein

First of all, completely de-install Oracle. You are not ready to use it
yet. Get something like Foxbase or Access that you can understand more
readily. Then take time to learn what you are doing and hire an Oracle DBA
to take care of managing your database for you. If you think that you can
create a database while logged in as SYSTEM, that is a strong indication
that you haven't the foggiest notion of what you are doing.

 
 
 

How can I create a new database ?

Post by Peterwete » Tue, 02 Apr 2002 16:33:46


Use dbassist.

--
Greets / Groeten,
Peter



Quote:> During installation of Oracle 9i I created the database
> databas1.Then I logged in as system/manager in SQL*Plus.Now I wanted to
> create a new database with
> "create database databas2;".
> But I get error messages:
> (I've translated my German messages to English, could be
> the messages are not exactly like in the English version:)

> Error in line one:
> ORA-01501: CREATE DATABASE not successfull
> ORA-01100: Database was connected with MOUNT
> already

> What's wrong ?

> Theo Klein

 
 
 

How can I create a new database ?

Post by Theo Klei » Tue, 02 Apr 2002 22:00:13


I can't believe that there is no way to create a database
in Oracle 9i without the configuration assisstent only
with the "create database" command.

Now I tried this:
Logged in as SYS/***:
grant create tablespace to scott;

Then I logged in as scott:
create database test;

But I get the error:
ORA-01031: Not enough rights

Which rights have I to give scott that he can create
databases ?
(I can't do this as SYS/***:
grant create database to scott;
Because I get this error:
ORA-00990:Missing or invalid right)

Pleas help me!

Theo Klein

 
 
 

How can I create a new database ?

Post by Jim Kenned » Tue, 02 Apr 2002 22:26:48


A tablespace and a database are not the same thing.  If you were able to
logon and grant scott a privlidge they you already have a database.  In
Oracle each instance is 1 database.  Each database can have multiple schemas
which is what you want.
Jim

Quote:> I can't believe that there is no way to create a database
> in Oracle 9i without the configuration assisstent only
> with the "create database" command.

> Now I tried this:
> Logged in as SYS/***:
> grant create tablespace to scott;

> Then I logged in as scott:
> create database test;

> But I get the error:
> ORA-01031: Not enough rights

> Which rights have I to give scott that he can create
> databases ?
> (I can't do this as SYS/***:
> grant create database to scott;
> Because I get this error:
> ORA-00990:Missing or invalid right)

> Pleas help me!

> Theo Klein

 
 
 

How can I create a new database ?

Post by Theo Klei » Tue, 02 Apr 2002 23:52:34



Quote:> A tablespace and a database are not the same thing.  If you were able to
> logon and grant scott a privlidge they you already have a database.  In
> Oracle each instance is 1 database.  Each database can have multiple
schemas
> which is what you want.
> Jim

No, sorry, I don't want schemas,I want a new database.
I'm new to oracle and thought it could be that I could create a new database
if I have the right to create tablespace.But now I read it's only to divide
an existing database in logical areas.I really want to execute the "create
database" command
in SQL*Plus. Which rights need I to do it ?
You wrote "If you were able to logon ... you already have a database".
Yes, I want only to logon to the existing database to start SQL*Plus to
create a new database. And I want to know it how to do it with command
lines for the case that I can't use the "database configuration assistent".

1)Is it possible to start SQL*Plus without an existing database only for
creating a new database ?
When it is possible what are the logon data ?

2)Which rights need I to use the CREATE DATABASE command ?

Theo Klein

 
 
 

How can I create a new database ?

Post by Jim Kenned » Wed, 03 Apr 2002 13:00:23


I suspect that you really do not want to create a new database.  What's
wrong with the one you have?  I suspect that you are coming from the ms sql
world and there you create new databases inside of instances.  That is not
what you do in Oracle.(different product.)  Instead an Oracle instance, and
you can have more than one instance per machine, is a database.  In each
database you have schemas.  Think of schemas as sql server type databases.
If you somehow give Scott enough rights to create a database and figure out
how to issue the command you will probably wipe out your current database.
You might not want to do that.

If you want to actually create a new database then you have to create a new
instance.  Best way to see how to do that is to use the dbassistant and
don't let it run the scripts.  Let it create the scripts for you and then
you can see what the scripts do.

(eg
connect internal
startup nomount
--there isn't a database so you can't mount anything
create database .....

)

Also look in the manual especially the sql reference manual.

Jim



> > A tablespace and a database are not the same thing.  If you were able to
> > logon and grant scott a privlidge they you already have a database.  In
> > Oracle each instance is 1 database.  Each database can have multiple
> schemas
> > which is what you want.
> > Jim

> No, sorry, I don't want schemas,I want a new database.
> I'm new to oracle and thought it could be that I could create a new
database
> if I have the right to create tablespace.But now I read it's only to
divide
> an existing database in logical areas.I really want to execute the "create
> database" command
> in SQL*Plus. Which rights need I to do it ?
> You wrote "If you were able to logon ... you already have a database".
> Yes, I want only to logon to the existing database to start SQL*Plus to
> create a new database. And I want to know it how to do it with command
> lines for the case that I can't use the "database configuration
assistent".

> 1)Is it possible to start SQL*Plus without an existing database only for
> creating a new database ?
> When it is possible what are the logon data ?

> 2)Which rights need I to use the CREATE DATABASE command ?

> Theo Klein

 
 
 

How can I create a new database ?

Post by Sybrand Bakke » Wed, 03 Apr 2002 02:54:23




> > A tablespace and a database are not the same thing.  If you were able to
> > logon and grant scott a privlidge they you already have a database.  In
> > Oracle each instance is 1 database.  Each database can have multiple
> schemas
> > which is what you want.
> > Jim

> No, sorry, I don't want schemas,I want a new database.
> I'm new to oracle and thought it could be that I could create a new
database
> if I have the right to create tablespace.But now I read it's only to
divide
> an existing database in logical areas.I really want to execute the "create
> database" command
> in SQL*Plus. Which rights need I to do it ?
> You wrote "If you were able to logon ... you already have a database".
> Yes, I want only to logon to the existing database to start SQL*Plus to
> create a new database. And I want to know it how to do it with command
> lines for the case that I can't use the "database configuration
assistent".

> 1)Is it possible to start SQL*Plus without an existing database only for
> creating a new database ?
> When it is possible what are the logon data ?

> 2)Which rights need I to use the CREATE DATABASE command ?

> Theo Klein

Apparently you want to create a new *instance* also, as *one* instance can
only manage *one* database. An instance is a set of processes and a cache in
memory which will manage your new database.
You CAN'T create a NEW database in your CURRENT instance
You need to create a NEW instance
Are you sure you really want this?
Are you aware a database in Oracle is definitely NOT the same as a database
in  sqlserver or sybase?
If you don't want to create a second instance and a second database, what
makes you think you can't change the current database to match what you
want?

If you want to proceed : You need to create an instance.
Find the instructions of how to create a new instance in your getting
started manual.

Regards