short/quick answer: yes, they are interchangable, however, symbols (what you
refer to as colons) are preferred in certain cases.
http://glu.ttono.us/articles/2005/08/19/understanding-ruby-symbols
On 6/7/06, Dark Ambient <sambient@gmail.com>
wrote:>
> Just started learning on rails. The first few time I edited a migration
> file it was using colons like:
>
> create_table :table do |t|
> t.column :column, :string
>
>
> Now I''m working on a tutorial where it''s using quotes for
the table and
> column names:
>
>
> reate_table "table" do |t|
> t.column "column", :string
>
> Are these two ways interchangeable ? Is there a preferred ?
>
> TIA
> Stuart
>
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://wrath.rubyonrails.org/pipermail/rails/attachments/20060607/cd6afbc0/attachment.html