timothymorgan-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2006-Aug-27 02:02 UTC
PostgreSQL and migrations
Just thought I''d pass a note of an error I see when using migrations with PostgreSQL. In a create_table |table| block, the line table.column :trinkets, :text, :limit => 8192 will create a PGError. It will try to turn that into a field "trinkets" text(8192) and since the text data type does not take a parameter, it produces an error. Removing the :limit option creates "trinkets" text which is valid. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
Try string instead? Joe -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
timothymorgan-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2006-Aug-27 03:08 UTC
Re: PostgreSQL and migrations
:text works fine for unbounded fields, and :string with :limit works fine for bounded fields. Only problem is when you use :limit with :text. This is more of an FYI than an actual problem. I''ve figured out the problem myself and solved it already. :) Tim Joe Ruby wrote:> Try string instead? > > Joe > > -- > Posted via http://www.ruby-forum.com/.--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---