Solved

How can you tell if a table has a sequence associated?

Posted on 2009-07-13
3
229 Views
Last Modified: 2012-05-07
I have numerous tables that I created sequences for and now want to ensure the sequences are in place...how do you check for this?

Thx
0
Comment
Question by:Glen_D
  • 2
3 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 24844553
you cannot. there is no dictionary indication in oracle for this.
you could check if there is a trigger on the table using a sequence, or some stored procedure doing the inserts while using the sequence, but it could be as well the client application itself.
0
 

Author Closing Comment

by:Glen_D
ID: 31603048
very surprized that you can't review all code within a db...thx
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 24844725
you can "look" at all the code of the views, triggers, procedures etc:
select * from dba_code

however, to "analyse" it to find out if there is a insert/update using a given sequence on a given table is VERY far from trivial. peanuts for the human reader, but using some "code" to "understand" the code ...
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and theā€¦
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
Via a live example, show how to take different types of Oracle backups using RMAN.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now