Re: ** find whether table or index being accessed

2003-11-20 Thread Tanel Poder
Yep, I missed this userenv part totally, even though I posted the source here myself as well. Gotta get better eyes from somewhere ;) Tanel. - Original Message - To: Multiple recipients of list ORACLE-L [EMAIL PROTECTED] Sent: Wednesday, November 19, 2003 5:10 PM Tanel, Raj must be

RE: ** find whether table or index being accessed

2003-11-19 Thread Jamadagni, Rajendra
MG, AFAIK v$object_usage is ONLY for current user ... you have to hack it to see remaining data. Raj Rajendra dot Jamadagni at nospamespn dot com All Views expressed in this email are strictly personal. QOTD: Any

Re: ** find whether table or index being accessed

2003-11-19 Thread Tanel Poder
Well, it's code is: select io.name, t.name, decode(bitand(i.flags, 65536), 0, 'NO', 'YES'), decode(bitand(ou.flags, 1), 0, 'NO', 'YES'), ou.start_monitoring, ou.end_monitoring from sys.obj$ io, sys.obj$ t, sys.ind$ i, sys.object_usage ou where io.owner# =

Re: ** find whether table or index being accessed

2003-11-19 Thread Yong Huang
Tanel, Raj must be talking about userenv('SCHEMAID'). Change that to another user's user_id as seen in dba_users, you should see that user's object usage: SQL select * from v$object_usage; no rows selected SQL select io.name, t.name, 2 decode(bitand(i.flags, 65536), 0, 'NO', 'YES'),

RE: ** find whether table or index being accessed

2003-11-19 Thread Jesse, Rich
The last statement here is not always true under CBO, at least in 8i. All unique indexes (no PKs, no FKs) on our 3rd-party ERP tables are segmented, and the last segment is always company code. Even though there is only one company code value for all rows in all tables, some queries that do not

** find whether table or index being accessed

2003-11-18 Thread A Joshi
Hi, I had sent this some time back but got no answer for version 8.1.7.For table I understand auditing is an option. What about for index? Thank YouA Joshi [EMAIL PROTECTED] wrote: Hi, Is there an easy way to find out if a table or anindex is being used. I mean short of going thru all code or

RE: ** find whether table or index being accessed

2003-11-18 Thread DENNIS WILLIAMS
A - The only suggestion I've heard is to take the contents of V$SQL, perform EXPLAIN PLAN on all SQL, and try to build a list of indexes that are used. Hardly foolproof. I think Burleson has some scripts in his book Oracle High-Performance Tuning With STATSPACK, IIRC. Dennis Williams DBA

Re: ** find whether table or index being accessed

2003-11-18 Thread Daniel Fink
Are you looking to see if statements are using indexes or how often index blocks are being read? Daniel Fink A Joshi wrote: Hi, I had sent this some time back but got no answer for version 8.1.7. For table I understand auditing is an option. What about for index? Thank You A Joshi [EMAIL

Re: ** find whether table or index being accessed

2003-11-18 Thread Mladen Gogala
Well, 'ALTER INDEX MONITORING USAGE' should do the trick. Results should be in V$OBJECT_USAGE. In connection to that, here is a sweet little bug in oracle 9.2.0.4: SQL select name from v$fixed_table where name='V$OBJECT_USAGE'; no rows selected Don't tell that to oracle, they might even fix

Re: ** find whether table or index being accessed

2003-11-18 Thread A Joshi
Looking to see if any statement has accessed the index in say 30 days. So basically : "how often index blocks are being read". So I can decide to drop unused indexes. T Thanks Daniel for your help. Daniel Fink [EMAIL PROTECTED] wrote: Are you looking to see if statements are using indexes or how

Re: ** find whether table or index being accessed

2003-11-18 Thread Jared . Still
... but the database is 8.1.7 - no monitoring allowed Mladen Gogala [EMAIL PROTECTED] Sent by: [EMAIL PROTECTED] 11/18/2003 12:44 PM Please respond to ORACLE-L To:Multiple recipients of list ORACLE-L [EMAIL PROTECTED] cc: Subject:Re: ** find whether table

Re: ** find whether table or index being accessed

2003-11-18 Thread Mladen Gogala
To: Multiple recipients of list ORACLE-L [EMAIL PROTECTED] cc: Subject:Re: ** find whether table or index being accessed Well, 'ALTER INDEX MONITORING USAGE' should do the trick. Results should be in V$OBJECT_USAGE. In connection to that, here is a sweet

Re: ** find whether table or index being accessed

2003-11-18 Thread Brian_P_MacLean
: [EMAIL PROTECTED]Subject: Re: ** find whether table or index being accessed .com

Re: ** find whether table or index being accessed

2003-11-18 Thread Daniel Fink
This is just an idea, so please test it thoroughly (and then test it again!) Any and all comments (including "Are you brain-dead, Dan?") are welcome. How about periodically sampling v$bh for index segment headers? This assumes that any index access reads the header (true/false?) for the

RE: ** find whether table or index being accessed

2003-11-18 Thread Joze Senegacnik
Daniel, it will work but indexes are present in buffer cache also because of updates. The only possibility is to store each index in questionin separate tablespace and monitor the i/o. If number of reads will be equal or little bit greaterthan thenumber of writes than this is a candidate.

Re: ** find whether table or index being accessed

2003-11-18 Thread Tanel Poder
Well, 'ALTER INDEX MONITORING USAGE' should do the trick. Results should be in V$OBJECT_USAGE. In connection to that, here is a sweet little bug in oracle 9.2.0.4: SQL select name from v$fixed_table where name='V$OBJECT_USAGE'; no rows selected Don't tell that to oracle, they might even

RE: ** find whether table or index being accessed

2003-11-18 Thread Jacques Kilchoer
I was too lazy to look for it on asktom.oracle.com, but here's what I read at the site a while ago (if you search on index usage or something like that you should find Mr. Kyte's answer). Tom Kyte has the following suggestions: a) In Oracle 8.0 and earlier - put an index all by itself in a

Re: ** find whether table or index being accessed

2003-11-18 Thread Daniel Fink
% sure.Regards, Joze -Original Message- From: Daniel Fink [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 18, 2003 10:34 PM To: Multiple recipients of list ORACLE-L Subject: Re: ** find whether table or index being accessed This is just an idea, so please test it thoroughly (and then test

Re: ** find whether table or index being accessed

2003-11-18 Thread Tanel Poder
Message - From: Daniel Fink To: Multiple recipients of list ORACLE-L Sent: Tuesday, November 18, 2003 11:34 PM Subject: Re: ** find whether table or index being accessed This is just an idea, so please test it thoroughly (and then test it again!) Any and all comments

RE: ** find whether table or index being accessed

2003-11-18 Thread Jared . Still
] cc: Subject:RE: ** find whether table or index being accessed I was too lazy to look for it on asktom.oracle.com, but here's what I read at the site a while ago (if you search on index usage or something like that you should find Mr. Kyte's answer). Tom Kyte has the following

Re: ** find whether table or index being accessed

2003-11-18 Thread Yong Huang
recipients of list ORACLE-L Sent: Tuesday, November 18, 2003 11:34 PM Subject: Re: ** find whether table or index being accessed This is just an idea, so please test it thoroughly (and then test it again!) Any and all comments (including Are you brain-dead, Dan?) are welcome. How about

Re: ** find whether table or index being accessed

2003-11-18 Thread Prem Khanna J
--Boundary-00=_4PUK6RO0 Content-Type: Multipart/Alternative; boundary=Boundary-00=_4PUK12S0 --Boundary-00=_4PUK12S0 Content-Type: Text/Plain; charset=shift_jis Content-Transfer-Encoding: quoted-printable Joshi,=0D =0D

** find whether table or index being accessed

2003-07-31 Thread A Joshi
Hi, Is there an easy way to find out if a table or anindex is being used. I mean short of going thru all code or keeping looking at v$sqlarea. I mean even if code is covered there are always ad hoc SQL queries etc. Same for other objects like views etc. Is there a place where oracle stores

RE: ** find whether table or index being accessed

2003-07-31 Thread DENNIS WILLIAMS
A - For tables, you can turn on auditing. If you are on Oracle9i, there is a monitoring feature for indexes you can turn on. Dennis Williams DBA, 80%OCP, 100% DBA Lifetouch, Inc. [EMAIL PROTECTED] -Original Message- Sent: Thursday, July 31, 2003 12:49 PM To: Multiple recipients of