dbTalk Databases Forums  

Re: Administration.

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss Re: Administration. in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Maxim Demenko
 
Posts: n/a

Default Re: Administration. - 06-01-2009 , 08:36 AM






Markus Gronotte schrieb:
Quote:
I do this Code as System:


Create Table T_Controlling (
ControllingID number,
Mitarbeiter number,
Verkaeufe number,
Constraint PK_Control Primary Key (ControllingID),
Constraint FK_Control Foreign Key (Mitarbeiter) References
Mitarbeiter(MitarbeiterID)
);




Create Role R_Einkauf
Create Role R_Verkauf




Grant Connect to R_Einkauf
Grant Connect to R_Verkauf

Grant Select On T_Controlling to R_Einkauf
Grant Select On T_Controlling to R_Verkauf

Grant Insert On T_Controlling to R_Einkauf
Grant Insert On T_Controlling to R_Verkauf

Grant Update On T_Controlling to R_Einkauf
Grant Update On T_Controlling to R_Verkauf

Grant Select On T_Mitarbeiter to R_Einkauf
Grant Select On T_Mitarbeiter to R_Verkauf



Grant Select On T_Waren to R_Einkauf
Grant Select On T_Lieferanten to R_Einkauf

Grant Select On T_Rechnung to R_Verkauf
Grant Select On T_Kunden to R_Verkauf



Create User Meyer Identified By "abc" Create User Moeller Identified
By "abc" Create User Mueller Identified By "abc" Create User Schmidt
Identified By "abc"


Grant R_Einkauf to Meyer
Grant R_Einkauf to Moeller Grant R_Verkauf to Mueller Grant R_Verkauf to
Schmidt

Then I log in with "Schmidt" and if i try to do
select * from T_Controlling Oracle says "ORA-00942: Table or View not
found.

Does anybody know why?

Yours,
Markus
Probably because the schema schmidt doesn't have a table or view
t_controlling.
It is hard to tell, because you don't provide an exact description, how
are you executing your steps ( for example, you are using mixed case in
object names and some environments - like ApEx - preserve mixed case,
doing it then not possible to access objects if not enclosed in quotes)
- the best description could be providing a script output from sqlplus.
But maybe it is simply absence of schema modifier by referencing the
object - so you could try to select from system.t_controlling - or
create a synonyms for tables in question.

Best regardes

Maxim

--
Why make things difficult, when it is possible to make them cryptic
and totally illogical, with just a little bit more effort?

Aksel Peter Jørgensen


Reply With Quote
  #2  
Old   
joel garry
 
Posts: n/a

Default Re: Administration. - 06-01-2009 , 03:15 PM






On Jun 1, 6:03*am, "Markus Gronotte" <maqq... (AT) gmx (DOT) de> wrote:
Quote:
I do this Code as System:

Besides what the others said, you probably don't want to use system
for tables you create. It's not the critical error of earlier
versions, but still considered bad form. If you need a controlling
schema, make one. Leave system and its tablespace alone, except for
supported DBA use.

jg
--
@home.com is bogus.
Black lines http://www.washingtonpost.com/wp-dyn...002114_pf.html


Reply With Quote
  #3  
Old   
Mark D Powell
 
Posts: n/a

Default Re: Administration. - 06-02-2009 , 08:22 AM



On Jun 1, 4:15*pm, joel garry <joel-ga... (AT) home (DOT) com> wrote:
Quote:
On Jun 1, 6:03*am, "Markus Gronotte" <maqq... (AT) gmx (DOT) de> wrote:

I do this Code as System:

Besides what the others said, you probably don't want to use system
for tables you create. *It's not the critical error of earlier
versions, but still considered bad form. If you need a controlling
schema, make one. *Leave system and its tablespace alone, except for
supported DBA use.

jg
--
@home.com is bogus.
Black lineshttp://www.washingtonpost.com/wp-dyn/content/article/2009/05/30/AR200...
Joel is correct. You really should create a new username, grant it
the desired privileges (perhaps DBA), and use it for your testing,
study, and maybe even development.

IMHO -- Mark D Powell --


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.