Add a column named "default"

My setup: Rails 2.3.10, Ruby 1.8.7

I would like to add a column to the database table named "default", is this allowed or reserved in Ruby, Rails, sqlite, postgresql ...?

+5
source share
3 answers

Here is a list of reserved words that do not play a friendly role as table columns in Rails http://oldwiki.rubyonrails.org/rails/pages/ReservedWords

If you use mysql, DEFAULT is a reserved word according to: http://dev.mysql.com/doc/refman/5.5/en/reserved-words.html

+3
source

" " - , dbms, 25 .

, , . ? -. , , , - "default @# $$% ^ @what?" , .

. , dbms 8 .

+3

DEFAULT - , , SQL. , , , , , - . .

+1
source

All Articles