Check if a table exists in Rails

I have a rake task that won’t work unless a table exists. I’m working with more than 20 engineers on a website so I want to make sure they have migrated the table before they can do a rake task which will populate that respective table.

Does AR have a method such as Table.exists? How can I make sure they have migrated the table successfully?

5 Answers
5

Leave a Comment