Hi Jitendra,
This should help
SELECT a.constraint_name Name, b.column_name Column_Name,b.position
Position,a.constraint_type Type,a.r_owner r_owner, a.r_constraint_name,
a.status status
FROM user_constraints a,user_cons_columns b
WHERE a.table_name = b.table_name
AND a.constraint_name = b.constraint_name
AND lower(a.table_name) = lower('&table_name')
ORDER BY 1,2,3
It will ask for table_name. Enter the table for which you want the
details.
Vikas Bhat
Senior Software Engineer,
FBSI Pvt Ltd.,
Embassy Golf Links Business Park,
Intermediate Ring Road,
Bangalore - 560071
Email - vikas.[Email address protected]
Ph:91-80-56916482
Mob:91-9845589149
Those who aspire for the light of sun; need to bear its heat.
Any comments or statements made in this email are not necessarily those
of Fidelity Business Services India Pvt. Ltd. or any of the Fidelity
Investments group companies. The information transmitted is intended
only for the person or entity to which it is addressed and may contain
confidential and/or privileged material. If you have received this in
error, please contact the sender and delete the material from any
computer. All e-mails sent from or to Fidelity Business Services India
Pvt. Ltd. may be subject to our monitoring procedures.
-----Original Message-----
From: jitendra
[mailto:oracledba-ezmlmshield-x24829688.[Email address protected]
Sent: Wednesday, August 31, 2005 4:03 PM
To: LazyDBA Discussion
Subject: To find out the constraints defined on a table
Hi friends
Can somebody please tell me how I can know what constraints have been
defined on a table
and also the definition of these constraints so that I can know which
fields made up the
primary key for example.
Regards
Jitendra.
--------
website: http://www.LazyDBA.com
Please don't reply to RTFM questions
Oracle documentation is here: http://tahiti.oracle.com
To unsubscribe: see http://www.lazydba.com/unsubscribe.html
To subscribe: see http://www.lazydba.com
By using this list you agree to these
terms:http://www.lazydba.com/legal.html
Oracle LazyDBA home page