Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: How to find constraints of a table using SQL
You will need two data dictionary views, USER_CONSTRAINTS and USER_CONS_COLUMNS. This first one will tell you all the constraints you have on all of your columns. Since constraints tend to apply to specific columns of a table, the USER_CONS_COLUMNS will help too!
HTH,
Brian
"Zhou, Xiaodong" wrote:
>
> Hi, there:
>
> I want to see the constraints(foreign key, primary key, etc.) of a table. I
> don't know how to do it in SQL. Will you please give me some advice?
> Thanks in advance!
>
> Yours xdzhou
-- ======================================== Brian Peasland Raytheons Systems at USGS EROS Data Center These opinions are my own and do not necessarily reflect the opinions of my company! ========================================Received on Sat Feb 24 2001 - 10:39:56 CST