Method: Lhm::Connection::DataMapperConnection#table_exists?
- Defined in:
- lib/lhm/connection.rb
#table_exists?(table_name) ⇒ Boolean
72 73 74 75 76 77 78 79 |
# File 'lib/lhm/connection.rb', line 72 def table_exists?(table_name) !!select_one(%Q{ select * from information_schema.tables where table_schema = '#{ @database_name }' and table_name = '#{ table_name }' }) end |