I've been developing locally in Rails 3 using a SQLite database. I
created a comments table in my DB using this migration:

http://pastie.org/1546705

Locally, I can type a 500-word essay into the comment box, hit post,
and it saves no problem. On Heroku, I got the following response from
the server logs when comments failed to post:

http://pastie.org/1546711

(the important bit being: PGError: ERROR:  value too long for type
character varying(255) )

This was weird since I thought I was using SQLite. A little digging
told me that Heroku automatically uses Postgress and manages the
translation automagically somehow. Cool -- except, looking up
postgress (I think), I'm STILL supposed to define the field a "string"
in my migration to get an unlimited, variable character field in the
DB:

http://www.postgresql.org/docs/8.4/static/datatype-character.html

Anyone have any ideas about why my production DB is rejecting the
longer strings, and maybe how I can fix it? I probably need to run an
additional migration, but I'm not sure what to define other than
"text"...

Any help much appreciated,

Cheers,
  - J

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.

Reply via email to