How could I disable my database FOREIGN KEYs in a Rake task?
Or, how could I call the execute() method in a Rake task?
I’m trying to perform something like:
task :delete_the_cippalippa => :environment do
# FIXME: execute() is undefined
execute “SET FOREIGN_KEY_CHECKS = 0”
[…some more code…]
# FIXME: as above
execute “SET FOREIGN_KEY_CHECKS = 1”