method

columns

Importance_0
v2.2.1 - Show latest stable - 0 notes - Class: ActiveRecord::ConnectionAdapters::MysqlAdapter
columns(table_name, name = nil) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/connection_adapters/mysql_adapter.rb, line 439
      def columns(table_name, name = nil)#:nodoc:
        sql = "SHOW FIELDS FROM #{quote_table_name(table_name)}"
        columns = []
        execute(sql, name).each { |field| columns << MysqlColumn.new(field[0], field[4], field[1], field[2] == "YES") }
        columns
      end
Register or log in to add new notes.