Dba_tab_privs
Hi
Can someone explain to me what is the meaning / use of dba_tab_privs using example below?
i spool this from my db,
1. Grantee = ABC123
2. Owner = SYS
3. Table_name = CTR_ACCESS
4. Grantor = SYS
5. Privilege = Read
6. Grantable = Yes
7. Hierarchy = No
I confuse with the 'Grantable' part.
Anyone?
Thanks
-Nonie
grant select on CTR_ACCESS to ABC123 with grant option ;Will allow ABC123 to grant select to other users on this object hence the grantable column will be YES.
grant select on CTR_ACCESS to ABC123;
Wont allow ABC123 to grant select to other users on this object hence the grantable column will be 'NO'
Similar Messages
-
Can not find a table in DBA_TAB_PRIVS and ROLE_TAB_PRIVS
I get a table 'KNA1', a table of SAP R3 ERP application, and tried to find out all privileges granted to 'KNA1'. Using the SQL statement below, I am sure 'KNA1' is existing.
SQL> SELECT * FROM DBA_OBJECTS WHERE OBJECT_NAME = 'KNA1';
OWNER
OBJECT_NAME
SUBOBJECT_NAME OBJECT_ID DATA_OBJECT_ID OBJECT_TYPE
CREATED LAST_DDL_ TIMESTAMP STATUS T G S
SAPR3
KNA1
7480 7480 TABLE
30-JUL-02 30-JUL-02 2002-07-30:15:26:22 VALID N N N
However, when I tried to find 'KNA1' in 'DBA_TAB_PRIVS' and 'ROLE_TAB_PRIVS', the result is 'no rows selected'.
SQL> SELECT * FROM SYS.DBA_TAB_PRIVS WHERE TABLE_NAME = 'KNA1';
no rows selected
SQL> SELECT * FROM ROLE_TAB_PRIVS WHERE TABLE_NAME = 'KNA1';
no rows selected
SQL> SELECT * FROM SYS.ROLE_TAB_PRIVS WHERE TABLE_NAME = 'KNA1';
no rows selected
Dose that answer mean 'KNA1' did not be granted to any user or role?
If it is true, why can I still use KNA1 wtihout any problem?
If it is not true, where can I find the privileges information related to 'KNA1'?
Thanks a lot.Yes, I have, I use 'SYS', with DBA role, to login Oracle. thanks for ur response, but could u please say more, because I can not get ur point. thank you.
-
How to grant priv in DBA_TAB_PRIVS
I logged in as system and I just execute below script, however Im getting error "SQL Error: ORA-00942: table or view does not exist
00942. 00000 - "table or view does not exist""
GRANT execute ON UTL_FILE TO USER1;
How to grant privilege on ult_file?
Edited by: 995017 on Apr 2, 2013 1:08 AM
Edited by: 995017 on Apr 2, 2013 1:14 AM995017 wrote:
I logged in as system and I just execute below script, however Im getting error "SQL Error: ORA-00942: table or view does not exist
00942. 00000 - "table or view does not exist""
GRANT execute ON UTL_FILE TO USER1;
How to grant privilege on ult_file?
Edited by: 995017 on Apr 2, 2013 1:08 AM
Edited by: 995017 on Apr 2, 2013 1:14 AMYour subject i s- Re: How to grant priv in DBA_TAB_PRIVS
But your message part talks about - GRANT execute ON UTL_FILE TO USER1;
What is your exact issue? -
Dba_tab_privs vs all_tab_privs
If we query all_tab_privs (as user SYSTEM) for a particular SCHEMA we get a different set of privs (just SELECT) than when we query dba_tab_privs (SELECT and INSERT, UPDATE) for the same OWNER.objects...why would that be?
Well they are almost identical, with some difference in underlying query.
DBA_TAB_PRIVS
select ue.name, u.name, o.name, ur.name, tpm.name,
decode(mod(oa.option$,2), 1, 'YES', 'NO'),
decode(bitand(oa.option$,2), 2, 'YES', 'NO')
from sys.objauth$ oa, sys.obj$ o, sys.user$ u, sys.user$ ur, sys.user$ ue,
table_privilege_map tpm
where oa.obj# = o.obj#
and oa.grantor# = ur.user#
and oa.grantee# = ue.user#
and oa.col# is null
and oa.privilege# = tpm.privilege
and u.user# = o.owner#ALL_TAB_PRIVS
select ur.name, ue.name, u.name, o.name, tpm.name,
decode(mod(oa.option$,2), 1, 'YES', 'NO'),
decode(bitand(oa.option$,2), 2, 'YES', 'NO')
from sys.objauth$ oa, sys.obj$ o, sys.user$ u, sys.user$ ur, sys.user$ ue,
table_privilege_map tpm
where oa.obj# = o.obj#
and oa.grantor# = ur.user#
and oa.grantee# = ue.user#
and oa.col# is null
and u.user# = o.owner#
and oa.privilege# = tpm.privilege
and (oa.grantor# = userenv('SCHEMAID') or
oa.grantee# in (select kzsrorol from x$kzsro) or
o.owner# = userenv('SCHEMAID')) -
Anonymous PL/SQL vs procedure inside package
It's probably quite simple problem but I'm not able to figure it out.
If I make an anonymous PL/SQL block
declare
l_counter number(4);
begin
SELECT *
into l_counter
FROM (SELECT count(*)
FROM SYS.all_objects
WHERE owner IN ('USER1', 'USER2')
AND object_type IN ('TABLE', 'VIEW')
minus
SELECT count(*)
FROM SYS.dba_tab_privs
WHERE grantee = 'TESTERS');
DBMS_OUTPUT.PUT_LINE(l_counter);
end;
then it works. The result is 2 which is correct because select statement returns 2 rows.
If I make procedure with the same code
create or replace PROCEDURE grant_privileges2
IS
l_counter NUMBER (4);
BEGIN
SELECT COUNT (*)
INTO l_counter
FROM (SELECT owner, object_name
FROM SYS.all_objects
WHERE owner IN ('USER1', 'USER2')
AND object_type IN ('TABLE', 'VIEW')
MINUS
SELECT owner, table_name
FROM SYS.dba_tab_privs
WHERE grantee = 'TESTERS);
DBMS_OUTPUT.put_line (l_counter);
END;
result is 0 which is not correct becuase select statement is the same as in anonymous pl/sql and it has to return 2 rows.
What I'm doing wrong?If the queries are the same then it works for me...
SQL> ed
Wrote file afiedt.buf
1 declare
2 l_counter number(4);
3 begin
4 SELECT *
5 into l_counter
6 FROM (SELECT count(*)
7 FROM SYS.all_objects
8 WHERE owner IN ('CRISP_ADMIN', 'CRISP_INTELL')
9 AND object_type IN ('TABLE', 'VIEW')
10 minus
11 SELECT count(*)
12 FROM SYS.dba_tab_privs
13 WHERE grantee = 'SYSTEM');
14 DBMS_OUTPUT.PUT_LINE(l_counter);
15* end;
SQL> /
431
PL/SQL procedure successfully completed.
SQL> ed
Wrote file afiedt.buf
1 create or replace procedure mytest is
2 l_counter number(4);
3 begin
4 SELECT *
5 into l_counter
6 FROM (SELECT count(*)
7 FROM SYS.all_objects
8 WHERE owner IN ('CRISP_ADMIN', 'CRISP_INTELL')
9 AND object_type IN ('TABLE', 'VIEW')
10 minus
11 SELECT count(*)
12 FROM SYS.dba_tab_privs
13 WHERE grantee = 'SYSTEM');
14 DBMS_OUTPUT.PUT_LINE(l_counter);
15* end;
SQL> /
Procedure created.
SQL> exec mytest;
431
PL/SQL procedure successfully completed. -
Table does not exist at dw.insertrow(0)
Hi,
I am trying to update an old PB app.
Background of the basic database structure:
my_data Table:
col1
col2 -- lookup to an_old_table.id
col3 -- newly added as lookup
my_new_lookup Table:
code -- 'linked' to col3 above
description
an_old_lookup table:
id -- 'linked' to my_data.col2
text
I have created a new lookup table in our oracle database, and added an extra column to an existing table this column matches the lookup code and we can pull the full description of the item from there.
I would like to add the new lookup table as a dropdown list in a window of my app.
There is already a dropdown list which does exactly this, displaying an_old_table.text in the dropdown but updating my_table.col2 with the id value.
I have attempted to duplicate this functionality exactly but with data from my_new_lookup to my_data.col3, but am failing somewhere.
I have created a new d_dddw_mynewdropdown, which in the preview window lists all my_new_lookup.description values from the database correctly.
In the datawindow, I added a column control, changed the edit to DropDownDW, making sure the DataWindow is d_dddw_mynewdropdown and display and data columns matched description and code respectively.
When I do a retreive on the datawindow within powerbuilder, with a record from the my_data table a dropdown box appears correctly in the preview window with the value matching the correct lookup description, so it is flowing through col3 > code > description correctly.
The datawindow is embedded into an application window, and this is where I think it is failing... The window has two datawindows on it and part of the open() function does:
If dw_one.Retrieve(ln_id,) > 0 Then
ll_row = dw_one.GetRow()
If dw_one.ShareData (dw_two) <> 1 Then
MessageBox ("Error", "Error in sharing data.")
Else
dw_two.ScrollToRow (ll_row)
End If
Which passes (IE does not display the message box)
It then executes:
dw_one.InsertRow(0)
dw_two.InsertRow(0)
Which is where the application displays an error message which says:
Select Error: ORA-00942: table or view does not exist
I stepped through the code in debug mode and discovered the error message comes from the dw_one.InsertRow(0) line.
If I press ok to the error, the application continues to run, but the value of the dropdown box is my_data.col3 (the 'linking' code, not the full description) and the dropdown when pressed is empty.
I am not sure what I have done wrong.. In powerbuilder itself everything seems to be working and connecting together as it should when I preview the data in the datawindows, but something about the application window has issues.
Has anyone experienced similar things? I do not know where else to look to fix this.
Thanks.This is correct. The application starts with a log in screen (we have over 80 users) the application then connects to the database using the credentials entered into the login screen.
The table was created under the db admin account.
I have very little Oracle experience. what would be the best way to do it so that all users who have access to the application also have access to this table?
From what I can work out, the application uses the "Other Users" folder under in the database tree in Oracle SQL Developer. The DB admin account is not in the list of users in this folder..
When I use the application and log in using the db admin credentials there is no error! So I just have to work out how to give all the users access to this table?!
is the
alter session set current_schema= <username of table creator>.
a PowerBuilder command that I should run after the users log into the app? or is it an Oracle Query?
Thanks! this is down the right track..
I ran a select * from all_tables query and compared the new table with others that are successfully being used by the application.. as far as I can see, they are exactly the same in terms of OWNER, TABLESPACE_NAME, CLUSTER_NAME, STATUS, BUFFER_POOL... The only thing different is my new table has GLOBAL_STATS = YES where the rest have NO.. not sure if that makes any difference..
The OWNER column is the database admin user for all tables used by the application
I also checked the DBA_TAB_PRIVS table and it has all the same info as the other tables aswell.. not sure where else to look. -
How To Modify Privileges For APEX Objects Granted To PUBLIC?
I have searched this forum but couldn't any threads relating to this...
We have APEX 3.0.1 installed in some 10g (10.2.0.2) databases that host GIS data. I was informed by a GIS administrator that when using ESRI tool to search for data, the objects that belongs to FLOWS_030000 schema and ones that were granted to PUBLIC are shown. He would like to know if there is a way to hide these objects so they don't show up on the list? There are about 176 objects granted to public from the flows_030000 schema.
Could we establish a different security scheme that could accomplish the same thing? Maybe we need to create a new account and a role. Grant all of the privileges for flows_030000 to public to the new role. Then grant the role to the new account and the flow_files schema?
Our goal here is to make the flows_030000 objects hidden from the ESRI tools and still have APEX working properly.If you look at the grants, you'll see that there are over 170 objects from the FLOWS_030000 granted to PUBLIC:
SQL> select count(*) from dba_tab_privs where owner= 'FLOWS_030000' and grantee = 'PUBLIC';
173
If we were go grant these privileges to a role, called APEX_APP_RU, and grant this role to APEX_PUBLIC_USER and any schemas an application is linked to (Workspace to Schema), would that be a workable solution?
The only problem I see right off hand that this might not work is that PUBLIC has synonyms created for the FLOWS_030000 objects. If we revoke the underlying privileges, because of the synonyms, this might not work.
SQL> select COUNT(*) from dba_synonyms where table_owner = 'FLOWS_030000' and owner = 'PUBLIC';
176
Does anyone else have any ideas? -
Error while taking dump using datapump
getting following error -
Export: Release 10.2.0.1.0 - Production on Friday, 15 September, 2006 10:31:41
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Starting "XX"."SYS_EXPORT_SCHEMA_02": XX/********@XXX directory=dpdump dumpfile=XXX150906.dmp logfile=XXX150906.log
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
ORA-39125: Worker unexpected fatal error in KUPW$WORKER.GET_TABLE_DATA_OBJECTS while calling DBMS_METADATA.FETCH_XML_CLOB []
ORA-31642: the following SQL statement fails:
BEGIN "DMSYS"."DBMS_DM_MODEL_EXP".SCHEMA_CALLOUT(:1,0,0,'10.02.00.01.00'); END;
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
ORA-06512: at "SYS.DBMS_METADATA", line 907
ORA-06550: line 1, column 7:
PLS-00201: identifier 'DMSYS.DBMS_DM_MODEL_EXP' must be declared
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPW$WORKER", line 6235
----- PL/SQL Call Stack -----
object line object
handle number name
2A68E610 14916 package body SYS.KUPW$WORKER
2A68E610 6300 package body SYS.KUPW$WORKER
2A68E610 9120 package body SYS.KUPW$WORKER
2A68E610 1880 package body SYS.KUPW$WORKER
2A68E610 6861 package body SYS.KUPW$WORKER
2A68E610 1262 package body SYS.KUPW$WORKER
255541A8 2 anonymous block
Job "XX"."SYS_EXPORT_SCHEMA_02" stopped due to fatal error at 10:33:12
Action required is contact customer support. And on metalink found a link that states it a bug in 10g release 1 that was suppose to be fixed in 10g release 1 version 4.
some of the default schemas were purposely dropped from the database. The only default schema available now are -
DBSNMP, DIP, OUTLN, PUBLIC, SCOTT, SYS, SYSMAN, SYSTEM, TSMSYS.
DIP, OUTLN, TSMSYS were created again.
Could this be a cause of problem??
Thanks in adv.Hi,
Below is the DDL taken from different database. Will this be enough ? One more thing please, what shall be the password should it be DMSYS.....since this will not be used by me but system.
CREATE USER "DMSYS" PROFILE "DEFAULT" IDENTIFIED BY "*******" PASSWORD EXPIRE DEFAULT TABLESPACE "SYSAUX" TEMPORARY TABLESPACE "TEMP" QUOTA 204800 K ON "SYSAUX" ACCOUNT LOCK
GRANT ALTER SESSION TO "DMSYS"
GRANT ALTER SYSTEM TO "DMSYS"
GRANT CREATE JOB TO "DMSYS"
GRANT CREATE LIBRARY TO "DMSYS"
GRANT CREATE PROCEDURE TO "DMSYS"
GRANT CREATE PUBLIC SYNONYM TO "DMSYS"
GRANT CREATE SEQUENCE TO "DMSYS"
GRANT CREATE SESSION TO "DMSYS"
GRANT CREATE SYNONYM TO "DMSYS"
GRANT CREATE TABLE TO "DMSYS"
GRANT CREATE TRIGGER TO "DMSYS"
GRANT CREATE TYPE TO "DMSYS"
GRANT CREATE VIEW TO "DMSYS"
GRANT DROP PUBLIC SYNONYM TO "DMSYS"
GRANT QUERY REWRITE TO "DMSYS"
GRANT SELECT ON "SYS"."DBA_JOBS_RUNNING" TO "DMSYS"
GRANT SELECT ON "SYS"."DBA_REGISTRY" TO "DMSYS"
GRANT SELECT ON "SYS"."DBA_SYS_PRIVS" TO "DMSYS"
GRANT SELECT ON "SYS"."DBA_TAB_PRIVS" TO "DMSYS"
GRANT SELECT ON "SYS"."DBA_TEMP_FILES" TO "DMSYS"
GRANT EXECUTE ON "SYS"."DBMS_LOCK" TO "DMSYS"
GRANT EXECUTE ON "SYS"."DBMS_REGISTRY" TO "DMSYS"
GRANT EXECUTE ON "SYS"."DBMS_SYSTEM" TO "DMSYS"
GRANT EXECUTE ON "SYS"."DBMS_SYS_ERROR" TO "DMSYS"
GRANT DELETE ON "SYS"."EXPDEPACT$" TO "DMSYS"
GRANT INSERT ON "SYS"."EXPDEPACT$" TO "DMSYS"
GRANT SELECT ON "SYS"."EXPDEPACT$" TO "DMSYS"
GRANT UPDATE ON "SYS"."EXPDEPACT$" TO "DMSYS"
GRANT SELECT ON "SYS"."V_$PARAMETER" TO "DMSYS"
GRANT SELECT ON "SYS"."V_$SESSION" TO "DMSYS"
The other database has the DMSYS and the status is EXPIRED & LOCKED but I'm still able to take the dump using datapump?? -
Error while giving permission to the users
hi..
while giving the grants to the users I have created, it is showing "Account not found"..
I have logged in through the credentials of Administrator and went to Administration--> manage interactive dashboards
There when i am clicking on Show Users and Groups, then i can see all those.
But when i am trying to give the users the necessary permissions, it is showing the above error.
please help...Hi,
I dnt understand ur 1st question.what u meant by uniq filed where u create user?
and for ur second question, u can check all ur users from dba_users.for their privilages, to check on permission, it's dba_tab_privs. I dnt knw if this is what ur asking for but here is the script.
SELECT t.grantee "User ID",t.privilege "Privilege",o.object_type, o.object_name, '' column_name
FROM dba_tab_privs t, dba_objects o
WHERE t.owner = o.owner
AND t.table_name = o.object_name
AND NOT o.owner IN ('SYS', 'SYSTEM')
AND NOT t.grantor IN ('SYS', 'SYSTEM')
AND t.grantee in (select username from dba_users
where username not in ('SYS','SYSTEM','))
AND NOT o.object_type IN ('QUEUE', 'TRIGGER', 'DIMENSION', 'CLUSTER',
'INDEX', 'INDEX PARTITION', 'INDEX SUBPARTITION', 'TABLE PARTITION',
'TABLE SUBPARTITION', 'JAVA CLASS') -
Oracle 10.2.05
Linux environment
I just granted a role to a user, but the user does not have privileges base on the role.
Here is what I did:
First create a user (db_user) using system id
Second, create role schema_admin_role
Then run the script to grant privileges to the role
(SELECT 'grant select, insert, update, delete on ' ||owner|| '.'||table_name || ' to schema_admin_role;' from dba_tables WHERE OWNER = 'another_schema';
Then run
grant schema_admin_role to db_user;
The problem:
When db_user tries to update table X own by another_schema, he gets not sufficent privileges
But when I run (select owner, table_name,privilege from dba_tab_privs where grantee = 'SCHEMA_ADMIN_ROLE'; ), I see all the privileges owned by this role.
Any solution from your end will be appreciated.sb92075 wrote:
did db_user start a new session after GRANT was issued?Yes he did - also when I try to list all privileges granted to db_user, I get no row seleted. On the other hand, when I query privileges granted to role schema_admin_role, I see all privileges granted earlier
example
select owner, table_name,privilege from dba_tab_privs where grantee = 'SCHEMA_ADMIN_ROLE'; ---Here we get all privileges
select owner, table_name,privilege from dba_tab_privs where grantee = 'DB_USER'; --No row seleted -
What are the privileges required for explain plan in Oracle 11g database
I am facing the problem in doing a explain plan for a view in Oracle 11g database. When I select from the view like this:
select * from zonewisearpu
It does a select on the view but when I give explain plan like
explain plan for
select * from zonewisearpu
I get the error like insufficient privileges.
Please let me know if things are getting missed out as I guess system level privileges are required to execute this.
I hope, my question is clear.
It’s a humble request to revert urgently if possible as I need to complete a task and do not know the way out.
Regards975148 wrote:
Thanks for your reply. I have found out that an explain plan is possible on the user's own objects and is not possible on the granted objects from a different schema. For eg, if I do a explain plan on a view querying on tables from a different view, it would not allow the explain plan to proceed. This could mean that explain plan needs different privileges than just a select.
Requesting for a revert to this.
Here is a simple test case that I have perfomed
SQL> create user test1 identified by test1;
User created.
SQL> create user test2 identified by test1;
User created.
SQL> grant connect, resource to test1,test2;
Grant succeeded.
SQL> create table test1.tab1 as select * from v$session;
Table created.
SQL> connect test2/test1
Conencted.
SQL> show user
USER is "TEST2"
SQL>
SQL> explain plan for
2 select sid,serial#,status,username from test1.tab1 where username<> '';
Explained.
SQL>
So, as can be seen I am able to do a explain plan from user test2 for tables belong to user test1.
As far as privileges are concerned, following is the list
SQL> select * from dba_role_privs where grantee in ('TEST1','TEST2') order by 1;
GRANTEE GRANTED_ROLE ADM DEF
TEST1 CONNECT NO YES
TEST1 RESOURCE NO YES
TEST2 CONNECT NO YES
TEST2 RESOURCE NO YES
SQL>
SQL> select grantee,owner,table_name,privilege from dba_tab_privs where grantee in ('TEST1','TEST2') order by 1;
GRANTEE OWNER TABLE_NAME PRIVILEGE
TEST2 TEST1 TAB1 SELECT
SQL>
SQL> select * from dba_sys_privs where grantee in ('TEST1','TEST2') order by 1;
GRANTEE PRIVILEGE ADM
TEST1 UNLIMITED TABLESPACE NO
TEST2 UNLIMITED TABLESPACE NO
SQL> -
After posting something here a few days back about the myriad views needing to be digested for the Fund.I Exam, I have just gleaned this lot from the Couchman book. No doubt some of the pros out there may well correct me, but this is simple what I have collected from the book, in the last 3 hours. Cheers.
Dictionary Views
Data Dictionary
Which users are in the database password file:
V$PWFILE_USERS
Where values set in the init.ora file can be viewed – all parameters:
V$PARAMETER
Script used to create the objects that comprise the data dictionary:
catalog.sql
To grant a special role to users so they can look at DBA views:
SELECT_CATALOG_ROLE
Information about all database objects in the database:
DBA_OBJECTS
Information about all tables in the database:
DBA_TABLES
Information about all indexes in the database:
DBA_INDEXES
Information about all views (including dictionary views) in the database:
DBA_VIEWS
Information about all sequences in the database:
DBA_SEQUENCES
Information about all users in the database:
DBA_USERS
Information about all constraints in the database:
DBA_CONSTRAINTS
Information about all table columns that have constraints on them:
DBA_CONS_COLUMNS
Information about all columns that have indexes on them in the database:
DBA_IND_COLUMNS
Information about all columns in all the tables in the database:
DBA_TAB_COLUMNS
Information about all the roles in the database:
DBA_ROLES
Information about all object privileges in the database:
DBA_TAB_PRIVS
Information about all system privileges granted to all users in the database:
DBA_SYS_PRIVS
Displays all PL/SQL source code in the database:
DBA_SOURCE
Information about all triggers in the database:
DBA_TRIGGERS
Information about object privileges granted to roles
ROLE_TAB_PRIVS
Information about system privileges granted to roles
ROLE_SYS_PRIVS
Information about roles granted to roles
ROLE_ROLE_PRIVS
Information about all tablespaces in the database:
DBA_TABLESPACES
Information about all profiles in the database:
DBA_PROFILES
For all parameters?
V$PARAMETER
General information about the database mounted to your instance:
V$DATABASE
Most information about the performance of the database is kept here:
V$SYSSTAT
Most information about the performance for individual user sessions is stored here:
V$SESSION , V$SESSTAT
Information about online redo logs (2)
V$LOG, V$LOGFILE
Information about datafiles
V$DATAFILE
Basic information about control files, and the two columns it has:
V$CONTROLFILE. STATUS / NAME
An object you can query to obtain a listing of all data dictionary objects (4)
CATALOG, CAT, DICTIONARY, DICT.
When the control file was created, Sequence Number, most recent SCN:
V$DATABASE
Information stored in different sections of the control file, Sequence Number:
V$CONTROLFILE_RECORD_SECTION
To see the names and locations of all control files in the db? (2)
V$PARAMETER. V$CONTROLFILE
Tablespace and Datafiles
Temporary Segments:
Name, tablespace location, and owner of temporary segments:
DBA_SEGMENTS
Size of temporary tablespaces, current number of extents allocated to sort segments, and sort segment high-water mark information. Space usage allocation for temporary segments:
V$SORT_SEGMENT
Types of sorts that are happening currently on the database
V$SORT_USAGE
To see the username corresponding with the session:
V$SESSION
Information about every datafile in the database associated with a temporary tablespace:
DBA_TEMP_FILES
Similar to DBA_TEMP_FILES, this performance view gives Information about every datafile in the database associated with a temporary tablespace:
V$TEMPFILE
Storage Structures
A summary view, contains all types of segments and their storage parameters, space utilization settings:
DBA_SEGMENTS
Tablespace quotas assigned to users:
DBA_TS_QUOTAS
Segment name, type, owner, total bytes of extent, name of tablespace storing the extent:
DBA_EXTENTS
The location and amount of free space by tablespace name:
DBA_FREE_SPACE
The location of free space in the tablespace that has been coalesced:
DBA_FREE_SPACE_COALESCED
Information about datafiles for every tablespace
DBA_DATAFILES
Performance view for information for datafiles for every tablespace
V$DATAFILE
To see the total amount of space allocated to a table?
DBA_EXTENTS
Table creation timestamp, information about the object ID:
DBA_OBJECTS
High water mark, all storage settings for a table, and statistics collected as part of the analyze (for row migration) operation on that table
DBA_TABLES
Information about every column in every table:
DBA_TAB_COLUMNS
To determine how many columns are marked unused for later removal?
DBA_UNUSED_COL_TABS
To find the number of deleted index entries ?
INDEX_STATS
To determine the columns on a table that have been indexed:
DBA_ID_COLUMNS
The dynamic view to show whether the index is being used in a meaningful way?
V$OBJECT_USAGE
To see whether a constraint exists on a particular column?
DBA_CONS_COLUMNS
To see the constraints associated with a particular table:
DBA_CONSTRAINTS
To find the username, ID number, (encrypted) password, default and temporary tablespace information, user profile of a user, password expiry date:
DBA_USERS
To all objects, which objects belong to which users, how many objects a user has created?
DBA_OBJECTS
Resource-usage parameters for a particular profile:
DBA_PROFILES
Identifies all resources in the database and their corresponding cost:
RESOURCE_COST
Identifies system resource limits for individual users:
USER_RESOURCE_LIMITS
Shows all system privileges:
DBA_SYS_PRIVS
Show all object privileges:
DBA_TAB_PRIVS
Shows all privileges in this session available to you as the current user:
SESSION_PRIVS
Views for audits currently taking place are created by this script:
cataudit.sql
a list of audit entries generated by the exists option of the audit command:
DBA_AUDIT_EXISTS
A list of audit entries generated for object audits:
DBA_AUDIT_OBJECT
A list of audit entries generated by session connects and disconnects:
DBA_AUDIT_SESSION
A list of audit entries generated by statement options of the audit command:
DBA_AUDIT_STATEMENT
A list of all entries in the AUD$ table collected by the audit command:
DBA_AUDIT_TRAIL
To determine the roles available in the database, the names of all the roles on the database and if a password is required to use each role:
DBA_ROLES
Names of all users and the roles granted to them:
DBA_ROLE_PRIVS
All the roles and the roles that are granted to them:
ROLE_ROLE_PRIVS
Which system privileges have been granted to a role:
DBA_SYS_PRIVS
All the system privileges granted only to roles:
ROLE_SYS_PRIVS
All the object privileges granted only to roles:
ROLE_TAB_PRIVS
All the roles available in the current session:
SESSION_ROLES
Which object privilege has been granted to a role:
DBA_TAB_PRIVS
To display the value of the NLS_CHARACTERSET parameter:
NLS_DATABASE_PARAMETERS
DAYou can also find a lot of stuff by doing:
SELECT *
FROM dictionary; -
How to make a table of the user to non public privilege?
Hi all,
im working with an RAD program and using oracle as the database. currently im on db 10g. I am able to connect to the db but the problem is it shows other users table. It is not only showing the tables of the user i connected to.
this is a problem since it will load other users' table which i dont need in my project.
now i've post around the forum of the RAD program regarding this and a particular user mentioned that he had the similar problem and it's probably because the all those tables showing up is public.
im getting tables from sys,sytem,syman and other preinstalled db user which i dont need to list out for my project.
is there really a condition where these tables are public? if so, how can i change it to private? any appropriate query would help.
i dont want it to show up on my RAD program all those unnecessary tables when i connect to one user for example user1.
anyone can help me out?
Thnx.T101_cyberdyne wrote:
Balazs Papp wrote:
in Oracle, there is a special role, called PUBLIC
anything granted to this role will be applied to every user (obviously, its PUBLIC)
for example SYSTEM.HELP is a "public" table, every user can read it without any permissions granted
you can check this with a query like this:
select * from dba_tab_privs where grantee='PUBLIC' and table_name='HELP';
revoking such permissions from the PUBLIC role is not recommended at all, as they are required for basic operation
disabling the PUBLIC role for a specific user is not possible as per the following note: Is it possible to exclude a user from PUBLIC scope? [ID 156303.1]So are you saying i'm stuck and there's nothing i could do to prevent these public table from showing?
well,this is dissapointing.I guess you need to step back and ask why this is a "problem". So far you've only indicated that you consider to BE a problem, but not WHY. Perhaps you are starting from a flawed assumption. -
SGA Size for 8.1.7.4 32 bit? , some Interview Questions
Hi buddies,
I got some interview questions, might be simple for geeks in DBA. I am in need of answers. Could anyone help me.
Thanks,
Raaj
1) Does windows NT support direct I/O?
Answer: Choose one of the answers that apply
A: No, only AIO
B: Yes, depending on hardware.
C: Yes.
D: No.
2) Can you take a coldbackup from solaris and use it on windows NT?
Answer: Choose one of the answers that apply
A: Yes.
B: Yes if RMAN backup performed from NT server.
C: Yes, after running RMAN convert.
D: No.
3) All of the following will alter the number of checkpoints that occur in one hour on the database, except one. Which is it?
Answer: Choose one of the answers that apply
A: Decreasing tablespace size
B: Decreasing size of redo log members
C: Setting LOG_CHECKPOINT_INTERVAL greater than the size of the redo log file
D: Setting LOG_CHECKPOINT_TIMEOUT to zero
4) The DBA is attempting to back up the Oracle database control file. After
issuing the ALTER DATABASE BACKUP CONTROLFILE TO TRACE command, where can the DBA find the backup control file creation materials Oracle created for him or her ?
Answer: Choose one of the answers that apply
A: USER_DUMP_DEST
B: LOG_ARCHIVE_DEST
C: CORE_DUMP_DEST
D: BACKGROUND_DUMP_DEST
5) What is the most important action a DBA must perform after changing the database from NOARCHIVELOG TO ARCHIVELOG?
Answer: Choose one of the answers that apply
A: Shutdown normal and restart the database
B: Perform a full logical database backup
C: Perform a full offline database backup
D: Manually switch the log files
6) Which of the following choices lists an ALTER USER option that can be executed by the user herself or himself?
Answer: Choose one of the answers that apply
A: DEFAULT TABLESPACE
B: IDENTIFIED BY
C: TEMPORARY TABLESPACE
D: PROFILE
7) You need to view the initialization parameter settings for your Oracle
database. Which of the following choices does not identify a method
you can use to obtain values set for your initialization parameters?
Answer: Choose one of the answers that apply
A: Issue SELECT * FROM DBA_PARAMETERS; from SQL*Plus
B: Issue SELECT * FROM V$PARAMETER; from SQL*Plus
C: Issue SHOW PARAMETERS from Server Manager
D: Use OEM Instance Manager
8) As a result of a media failure, the current online redo log group is corrupted, the database crashes, as the current online group is inaccessible. Which type of incomplete recovery are you most likely to perform ?
Answer: Choose one of the answers that apply
A: Change-based
B: Time-based
C: Recovery using a backup control file
D: Cancel-based
9) User SNOW executes the following statement: SELECT * FROM EMP. This
statement executes successfully, and SNOW can see the output. Table
EMP is owned by user REED. What object would be required in order for
this scenario to happen ?
Answer: Choose one of the answers that apply
A: User SNOW would need the role to view table EMP.
B: User SNOW would need the privileges to view table EMP.
C: User SNOW would need a synonym for table EMP.
D: User SNOW would need the password for table EMP.
10) Which one of the following statements is true?
Answer: Choose one of the answers that apply
A: The request queue is common, and the response queue is different for all the dispatchers.
B: The request queue and response queue are different for all the dispatchers.
C: The request queue is different, and response queue is common for all the dispatchers.
D: The request queue and response queue are common for all the dispatchers.
11) What is the largest SGA size for 8.1.7.4 32 bit?
Answer: Choose one of the answers that apply
A: approximately 2GB
B: approximately 3.5GB
C: approximately 4GB
D: approximately 8GB
E: approximately 16GB
12) The DBA is about to perform some administrative tasks. Specifying the
OPTIMAL parameter has which of the following appropriate uses?
Answer: Choose one of the answers that apply
A: Limiting concurrent users
B: Limiting concurrent transactions
C: Limiting growth of rollback segments
D: Limiting growth of tables
13) If the DBA wants to find information about how often transactions are
wrapping transaction information between multiple rollback segment
extents, where would the DBA look to find that information?
Answer: Choose one of the answers that apply
A: DBA_ROLLBACK_SEGS
B: V$ROLLSTAT
C: V$ROLLNAME
D: DBA_SEGMENTS
14) You have 30 rollback segments in your database, for which
TRANSACTIONS_PER_ ROLLBACK_SEGMENT is set to 49 and
TRANSACTIONS is set to 1000. During periods of heavy usage, about how many rollback segments will be actively used by Oracle?
Answer: Choose one of the answers that apply
A: 50
B: 60
C: 20
D: 30
15) The DBA has a table created with the following statement:
CREATE TABLE EMPL
(EMPID NUMBER(10),
LASTNAME VARCHAR2(40),
RESUME LONG RAW);
The DBA attempts to issue the following statement:
ALTER TABLE EMPL
ADD ( PERF_APPRAISE LONG);
What happens?
Answer: Choose one of the answers that apply
A: The statement succeeds.
B: The statement succeeds, but column is added as VARCHAR2.
C: The statement fails.
D: The statement adds a disabled constraint.
16) The primary key of the EMP table has three columns, EMPID, LASTNAME,
and FIRSTNAME. You issue the following SELECT statement:
SELECT * FROM EMP WHERE LASTNAME = 'HARRIS' AND FIRSTNAME = 'BILLI'
AND EMPID = '5069493';
Where would you look to see if this query will use the index associated
with the primary key?
Answer: Choose one of the answers that apply
A: DBA_IND_COLUMNS
B: DBA_TAB_COLUMNS
C: DBA_INDEXES
D: DBA_CLU_COLUMNS
17) You are configuring your index to be stored in a tablespace. Which of the
following storage parameters are not appropriate for indexes?
Answer: Choose one of the answers that apply
A: OPTIMAL
B: INITIAL
C: PCTINCREASE
D: NEXT
18) You need to set up auditing in an order entry and product shipment
application so that when the ORDER_STATUS column in the ORDERS
table changes to SHIPPED, a record is placed in a special table associated
with a part of the application that gives sales representatives a daily list
of customers to call on a follow-up to make sure the customer is satisfied
with the order. Which of the following choices represents the best way
to perform this auditing?
Answer: Choose one of the answers that apply
A: Statement auditing
B: Object auditing
C: Audit by access
D: Value-based auditing
19) Information in the buffer cache is saved back to disk in each of the
following situations except one. In which situation does this not occur?
Answer: Choose one of the answers that apply
A: When a time-out occurs
B: When a log switch occurs
C: When the shared pool is flushed
D: When a checkpoint occurs
20) In order to allow remote administration of users and tablespaces on an Oracle database, which of the following types of files must exist in the database?
Answer: Choose one of the answers that apply
A: Password file
B: Initialization file
C: Datafile
D: Control file
E: Nothing, SYSDBA privileges are not required for these actions.
21) You are planning the storage requirements for your database. Which of the following is an effect of maintaining a high PCTFREE for a table?
Answer: Choose one of the answers that apply
A: Oracle will manage filling data blocks with new records more actively.
B: Oracle will manage filling data blocks with new records less actively.
C: Oracle will leave more space free in data blocks for existing records.
D: Oracle will leave less space free in data blocks for existing records.
22) You manage database access privileges with roles where possible.
You have granted the SELECT_MY_TABLE role to another role, called
EMP_DEVELOPER. To view information about other roles that may be
granted to EMP_DEVELOPER, which of the following dictionary views
are appropriate?
Answer: Choose one of the answers that apply
A: DBA_ROLE_PRIVS
B: DBA_TAB_PRIVS
C: USER_SYS_PRIVS
D: ROLE_ROLE_PRIVS
23) In order to set your SQL*Plus session so that your NLS_DATE_FORMAT
information is altered in a specific way every time you log into Oracle,
what method would be used?
Answer: Choose one of the answers that apply
A: Setting preferences in the appropriate menu option
B: Creating an appropriate LOGIN.SQL file
C: Issuing the ALTER USER statement
D: Issuing the ALTER TABLE statement
24) You create a sequence with the following statement:
CREATE SEQUENCE MY_SEQ
START WITH 394
INCREMENT BY 12
NOMINVALUE
NOMAXVALUE
NOCACHE
NOCYCLE;
Two users have already issued SQL statements to obtain NEXTVAL, and
four more have issued SQL statements to obtain CURRVAL. If you issue a
SQL statement to obtain the NEXTVAL, what will Oracle return?
Answer: Choose one of the answers that apply
A: 406
B: 418
C: 430
D: 4421.-
2.c
3.a
4.a
5.c
6.b
7.a
8.d
9.b
10.a -
11.a
12.c
13.b
14.d
15.c
16.a -
17.a
18.d
19.c
20.a
21. -
22.d
23.b
24.?
hope it helps u.
Thanks
Kuljeet -
Invalid objects after upgrade 8.1.7 to 9.2.0.6
I upgraded the database from 8.0.5 under EBS 11.0.3 to 8.1.7 then from 8.1.7 to 9.2.0.6 under EBS 11.5.10.2
in front of try to compile objects with utlrp, utlrcmp or compile i can't make these objects valid!
can any one help me please?
my invalids objects & errors from dba_errors are :
OWNER NAME TEXT
SYSTEM AD_APPS_PRIVATE PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_APPS_PRIVATE PL/SQL: SQL Statement ignored
SYSTEM AD_APPS_PRIVATE PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_APPS_PRIVATE PL/SQL: SQL Statement ignored
SYSTEM AD_COMPILE PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_COMPILE PL/SQL: SQL Statement ignored
SYSTEM AD_INST PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_INST PL/SQL: SQL Statement ignored
SYSTEM AD_INST PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_MCURR PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_MCURR PL/SQL: SQL Statement ignored
SYSTEM AD_PARALLEL_COMPILE_PKG PL/SQL: ORA-00942: table or view does not exist
SYSTEM AD_PARALLEL_COMPILE_PKG PL/SQL: SQL Statement ignored
CTXSYS CTX_ACCESS PLS-00201: identifier 'SYS.DBA_SYNONYMS' must be declared CTXSYS CTX_ACCESS PL/SQL: SQL Statement ignored
CTXSYS CTX_ACCESS PLS-00201: identifier 'SYS.DBA_OBJECTS' must be declared
CTXSYS CTX_ACCESS PL/SQL: SQL Statement ignored
CTXSYS CTX_ADM PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS CTX_ADM PL/SQL: Statement ignored
CTXSYS CTX_DDL PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS CTX_DDL PL/SQL: Item ignored
CTXSYS CTX_DDL PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS CTX_DML PLS-00201: identifier 'DBMS_LOCK' must be declared
CTXSYS CTX_DML PL/SQL: Statement ignored
CTXSYS CTX_LING PLS-00593: default value of parameter "LOG_MODE" in body
must match that of spec
CTXSYS CTX_QUERY PLS-00201: identifier 'DBA_OBJECTS' must be declared
CTXSYS CTX_QUERY PL/SQL: SQL Statement ignored
CTXSYS CTX_VP PLS-00201: identifier 'DBA_OBJECTS' must be declared
CTXSYS DISPATCHER PLS-00201: identifier 'DBMS_PIPE' must be declared
CTXSYS DISPATCHER PL/SQL: Declaration ignored
CTXSYS DMLQ PLS-00201: identifier 'DBMS_LOCK' must be declared
CTXSYS DMLQ PL/SQL: Statement ignored
CTXSYS DRASERM PLS-00593: default value of parameter "PERSON_MASK" in b
ody must match that of spec
CTXSYS DRDBG PLS-00201: identifier 'DBMS_PIPE' must be declared
CTXSYS DRDBG PLS-00201: identifier 'DBMS_PIPE' must be declared
CTXSYS DRDBG PL/SQL: Statement ignored
CTXSYS DRICON PLS-00201: identifier 'DBA_TAB_PRIVS' must be declared
CTXSYS DRICON PL/SQL: SQL Statement ignored
CTXSYS DRICON PL/SQL: SQL Statement ignored
CTXSYS DR_IDX PLS-00201: identifier 'DBMS_LOCK' must be declared
CTXSYS DR_IDX PL/SQL: Statement ignored
CTXSYS DR_REC PL/SQL: SQL Statement ignored
CTXSYS DR_REC PLS-00201: identifier 'SYS.USER$' must be declared
CTXSYS DR_REC PL/SQL: SQL Statement ignored
CTXSYS DR_REWRITE PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS DR_REWRITE PL/SQL: Statement ignored
CTXSYS DR_REWRITE PLS-00201: identifier 'SYS.USER$' must be declared
CTXSYS DR_REWRITE PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS DR_REWRITE PL/SQL: Item ignored
CTXSYS DR_RTM PLS-00201: identifier 'DBMS_LOCK' must be declared
CTXSYS DR_RTM PL/SQL: Statement ignored
CTXSYS DR_UTL PLS-00302: component 'IS_PARALLEL_SERVER' must be declar
ed
CTXSYS DR_UTL PL/SQL: Statement ignored
CTXSYS LISTENER PLS-00905: object CTXSYS.DISPATCHER is invalid
CTXSYS LISTENER PL/SQL: Item ignored
CTXSYS LISTENER PLS-00320: the declaration of the type of this expressio
n is incomplete or malformed
CTXSYS LISTENER PL/SQL: Statement ignored
CTXSYS LISTENER PLS-00320: the declaration of the type of this expressio
n is incomplete or malformed
CTXSYS PIPE PL/SQL: Statement ignored
CTXSYS PIPE PLS-00201: identifier 'DBMS_PIPE' must be declared
CTXSYS PIPE PL/SQL: Statement ignored
CTXSYS SVCQ PLS-00201: identifier 'DBMS_LOCK' must be declared
CTXSYS SVCQ PL/SQL: Statement ignored
APPS AD_DD PLS-00593: default value of parameter "P_DESCRIPTION" in
body must match that of spec
APPS AK_ATTRIBUTE_PVT PLS-00593: default value of parameter "P_DATA_TYPE" in b
ody must match that of spec
APPS AK_ATTRIBUTE_PVT PLS-00593: default value of parameter "P_PASS" in body m
ust match that of spec
APPS AK_OBJECT_GRP PLS-00593: default value of parameter "P_VALUE_VARCHAR2"
in body must match that of spec
APPS AS_OPPORTUNITY_PUB PLS-00593: default value of parameter "P_DEFAULT_FORECAS
TING_INFO" in body must match that of spec
APPS AS_OPPORTUNITY_PVT PLS-00593: default value of parameter "P_DEFAULT_FORECAS
TING_INFO" in body must match that of spec
APPS AS_QUOTE_PVT PLS-00593: default value of parameter "P_QUOTE_STATUS" i
n body must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_PERIOD" in body
must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_CCID" in body m
ust match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_BALSEGL" in bod
y must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_BALSEGH" in bod
y must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_ACCSEGL" in bod
y must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_ACCSEGH" in bod
y must match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_TPID" in body m
ust match that of spec
APPS AX_CALCULATE_BALANCES_PKG PLS-00593: default value of parameter "P_SUBID" in body
must match that of spec
Regards.
e-mail : [email protected]thank you for your answer,
i followed all documentation from oracle support, first document is
Upgrading Oracle Applications
Release 11i (11.5.10)
Part No. B13584-01
i used also "Installation Guide Using Rapid Install.pdf" chapter 4
first thing is that i upgraded database from 8.0.5 under EBS 11.0.3/win 2000 to 8.1.7 on an intermediate machine. then, i prepared environnement on an other machine with EBS 11.5.10.2 under windows 2003 (for the database, i have now only software) then i copied upgraded 8.1.7 database from intermediate machine to 11i machine then i upgraded it to 9.2.0.6 like it recommeded in category3 database tasks in "Upgrading Oracle Applications" documentation.
have u any idea, what's the probleme with these invalid objects?
regards.
Maybe you are looking for
-
Every time I try to delete my messages, I will delete and then restart the app or it won't work. When I restart the app, it takes me to an empty message screen and then will completely freeze. My phone will vibrate like I am receiving messages, but n
-
Why can't I add photos to my iPod Touch?
Using iTunes 10.2.2 iTunes Help instructions "Add photos to iPod, iPhone, and iPad" just downloaded. Instructions say "To also move the full-resolution versions of these photos to your iPod, select "Include full-resolution photos."" There is no "Incl
-
How I fixed my Home Sharing iTunes Issue
I had a very old version of I Tunes running on a Windows XP laptop. I upgraded my Iphone to IOS 7 today, my Apple TV too and decided to refresh my version of ITunes on my laptop to make sure it'd all still be compatible with IOS 7. Everything stopp
-
Command S not working in Dreamweaver CS6
Command S not working in Dreamweaver CS6
-
My Adobe Revel Premium was auto renewed it's annual fee on April 10th and I was having an Applecare supporting period for reinstalling my Macbook pro and home networking setup for my time capsule. I only noticed the charged when the 50$ apple store g