Quantcast

Newbie question

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Newbie question

Alie Eiseman
Hi I deployed foodsoft locally but when I go to localhost:3000 my page looks like a back-end page with All frame, local variables, instance variables, local variables, etc. How do I access the front-end login page of foodsoft?

Thanks!
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Newbie question

wvengen
Administrator
Hi, this probably is the development error console. What message does it give on top? Chances are that you still need to setup (or migrate) the database.

- Willem

On April 16, 2016 3:22:03 PM CEST, "Alie Eiseman [via foodsoft]" <[hidden email]> wrote:
Hi I deployed foodsoft locally but when I go to localhost:3000 my page looks like a back-end page with All frame, local variables, instance variables, local variables, etc. How do I access the front-end login page of foodsoft?

Thanks!


If you reply to this email, your message will be added to the discussion below:
http://foodsoft.51229.x6.nabble.com/Newbie-question-tp1233.html
To start a new topic under foodsoft-discuss, email [hidden email]
To unsubscribe from foodsoft-discuss, click here.
NAML
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Migration Error

Alie Eiseman
Hi Willem,

Thanks for the quick reply!

You're right the error at the top says:
ActiveRecord::PendingMigrationError at /
Migrations are pending

so i need to execute the command:
 bin/rake db:migrate RAILS_ENV=development

but when I do I get the error :
rake aborted!
StandardError: An error has occurred, all later migrations canceled:
Mysql2::Error: Table 'users' already exists: CREATE TABLE `users` (`id` int(11) auto_increment PRIMARY KEY, `nick` varchar(255) NOT NULL, `password_hash` varchar(255) NOT NULL, `password_salt` varchar(255) NOT NULL, `first_name` varchar(255) NOT NULL, `last_name` varchar(255) NOT NULL, `email` varchar(255) NOT NULL, `phone` varchar(255), `address` varchar(255), `created_on` datetime NOT NULL) ENGINE=InnoDB

I've never worked with an sql database before but I'm guess there's a file or table I need to delete somewhere?
Any advice would be helpful.

-Alie
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Migration Error

Alie Eiseman
So I deleted the users table in foodsoft_development, but now I get the error

Mysql2::Error: Table 'foodsoft_development.settings' doesn't exist: SHOW FULL FIELDS FROM `settings`

any advice?

Thanks!
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Migration Error

wvengen
Administrator
Hi,

It sounds like you don't have any valuable information in your database. Then it would be easiest to re-create it completely (assuming you've checked out the git repository):
$ git checkout db/schema.rb  # to make sure you have the stock version
$ rake db:drop db:setup
If you still get a migration error, something is wrong with the source-code (outdated database schema). You can try running rake db:migrate and may be lucky. If that doesn't work either, get the latest stable version of Foodsoft (which was tested more than master):
$ git checkout db/schema.rb  # to allow the next checkout in case the database schema changed
$ git checkout latest-release
$ rake db:drop db:setup
Does that help a bit?

- Willem

On 22-04-16 14:24, Alie Eiseman [via foodsoft] wrote:
So I deleted the users table in foodsoft_development, but now I get the error

Mysql2::Error: Table 'foodsoft_development.settings' doesn't exist: SHOW FULL FIELDS FROM `settings`

any advice?

Thanks!

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Migration Error

Alie Eiseman
Wow! Thanks that was exactly what I needed!
Your the best!
Loading...