Get The Column Names For A Model
An ActiveRecord
model is backed by a table in your application's database. We can get the column names for a backing table with ActiveRecord
s help using the .column_names
method.
Any ActiveRecord
model will have access to this class method.
See the docs for more details.
Last updated