Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: query whether sequences exist
Daniel Wetzler wrote:
> Dear Oracle Experts,
>
> I'M searching for a query to find out whether sequences for auto
> iteration of primary key columns do exist on a table or not.
> Does anyone know how to get that information ?
>
> Best regards,
>
> Daniel Wetzler
Seems likely you don't know what a sequence is because a query as to whether a sequence exists is easy:
SELECT COUNT(*)
FROM user_sequences
WHERE sequence_name = '...';
But what that sequence may or may not be used to do is impossible to discern. Yes you could look at trigger bodies but that may or may not be the location of NEXTVAL.
-- Daniel A. Morgan http://www.psoug.org damorgan_at_x.washington.edu (replace x with u to respond)Received on Wed Mar 01 2006 - 11:51:07 CST