diff options
Diffstat (limited to 'activerecord/lib/active_record')
-rwxr-xr-x | activerecord/lib/active_record/base.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index aa90e8bcc2..c46e97b1b7 100755 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -862,6 +862,11 @@ module ActiveRecord #:nodoc: end end + # Returns a string looking like: #<Post id:integer, title:string, body:text> + def inspect + "#<#{name} #{columns.collect { |c| "#{c.name}:#{c.type}" }.join(", ")}>" + end + def quote_value(value, column = nil) #:nodoc: connection.quote(value,column) |