This project is archived and is in readonly mode.
Migration Issue
Reported by Ally Raza | February 2nd, 2011 @ 06:25 AM
Hi
I started using Rails recently about 2 months ago please excuse my
English. I start with creating new rails app after that i run
generator to generate a scaffold and then i run migration to
migrate the database it gives me the following error
$ rake db:migrate (in User/Sites/app) rake aborted!
/Users/apple2/Sites/app/db/migrate/20110202061554_create_pages.rb:4:
syntax error, unexpected '\n', expecting tCOLON2 or '[' or '.'
(See full trace by running task with --trace)
what happens it adds a extra comma in migration file that causes
the problem
I have found a way around i thought let me just inform to Rails
core team so that they can fix it.
I have attached screen shots as well you can have look
cheers
Comments and changes to this ticket
-
Rohit Arondekar February 2nd, 2011 @ 10:02 AM
- Importance changed from to Low
Can you please mention the full command you used to generate the scaffold.
-
Rohit Arondekar February 2nd, 2011 @ 10:30 AM
- State changed from new to invalid
Try this
rails generate scaffold Page title:string body:text
You don't need a comma to separate the fields.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>