শুধু ফরেন কী কনস্ট্রেইন্ট দেখতে information_schema.referential_constraints ব্যবহার করুন। কোয়েরি:
mysql> select * -> from information_schema.referential_constraints -> where constraint_schema = 'business';
ফলাফল (৬টি ফরেন কী):
+--------------------+-------------------+--------------------------+---------------------------+--------------------------+------------------------+--------------+-------------+-------------+-------------------+-----------------------+ | CONSTRAINT_CATALOG | CONSTRAINT_SCHEMA | CONSTRAINT_NAME | UNIQUE_CONSTRAINT_CATALOG | UNIQUE_CONSTRAINT_SCHEMA | UNIQUE_CONSTRAINT_NAME | MATCH_OPTION | UPDATE_RULE | DELETE_RULE | TABLE_NAME | REFERENCED_TABLE_NAME | +--------------------+-------------------+--------------------------+---------------------------+--------------------------+------------------------+--------------+-------------+-------------+-------------------+-----------------------+ | def | business | ConstChild | def | business | PRIMARY | NONE | NO ACTION | NO ACTION | childdemo | parentdemo | | def | business | ConstFK | def | business | PRIMARY | NONE | NO ACTION | NO ACTION | tblf | tblp | | ... (অন্যান্য) ... | | def | business | primarytable1demo_ibfk_1 | def | business | PRIMARY | NONE | NO ACTION | NO ACTION | primarytable1demo | foreigntable1 | +--------------------+-------------------+--------------------------+---------------------------+--------------------------+------------------------+--------------+-------------+-------------+-------------------+-----------------------+ 6 rows in set (0.07 sec)
এই কোয়েরি ফরেন কী কনস্ট্রেইন্টের নাম, রেফারেন্স টেবিল, আপডেট/ডিলিট রুল ইত্যাদি দেখায়।