Query to find foreign keys
问题 I have a database where I need to drop some foreign keys, but I don't know beforehand whether the foreign keys still exist. I've found some stored procedures (http://forums.mysql.com/read.php?97,218825,247526) that does the trick, but I don't want to create a stored procedure for this. I've tried to use the query inside the stored procedure, but I get an error using "IF EXISTS (SELECT NULL FROM etc.. etc... Can I only use IF EXISTS in stored procedures? right now, the only thing I can run is