Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rake db:migrate not running #3914

Open
arungoel123456 opened this issue Nov 7, 2018 · 4 comments
Open

rake db:migrate not running #3914

arungoel123456 opened this issue Nov 7, 2018 · 4 comments
Labels
help wanted requires help by anyone willing to contribute installation

Comments

@arungoel123456
Copy link
Contributor

Please describe the problem (or idea)

What happened just before the problem occurred? Or what problem could this idea solve?

Not running mysql today.
== 20120101000000 DrupalSchema: migrating =====================================
-- table_exists?("comments")
-> 0.0002s
-- adapter_name()
-> 0.0000s
-- create_table("comments", {:primary_key=>"cid", :options=>"ENGINE=MyISAM"})
rake aborted!
StandardError: An error has occurred, this and all later migrations canceled:

SQLite3::SQLException: near "ENGINE": syntax error: CREATE TABLE "comments" ("cid" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "pid" integer DEFAULT 0 NOT NULL, "nid" integer DEFAULT 0 NOT NULL, "uid" integer DEFAULT 0 NOT NULL, "subject" varchar(64) DEFAULT '' NOT NULL, "comment" text(2147483647) NOT NULL, "hostname" varchar(128) DEFAULT '' NOT NULL, "timestamp" integer DEFAULT 0 NOT NULL, "status" integer(1) DEFAULT 0 NOT NULL, "format" integer(2) DEFAULT 0 NOT NULL, "thread" varchar NOT NULL, "name" varchar(60), "mail" varchar(64), "homepage" varchar) ENGINE=MyISAM
/home/arun/Desktop/plots2-master/db/migrate/20120101000000_drupal_schema.rb:4:in up' /home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in eval'
/home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in `

'

Caused by:
ActiveRecord::StatementInvalid: SQLite3::SQLException: near "ENGINE": syntax error: CREATE TABLE "comments" ("cid" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "pid" integer DEFAULT 0 NOT NULL, "nid" integer DEFAULT 0 NOT NULL, "uid" integer DEFAULT 0 NOT NULL, "subject" varchar(64) DEFAULT '' NOT NULL, "comment" text(2147483647) NOT NULL, "hostname" varchar(128) DEFAULT '' NOT NULL, "timestamp" integer DEFAULT 0 NOT NULL, "status" integer(1) DEFAULT 0 NOT NULL, "format" integer(2) DEFAULT 0 NOT NULL, "thread" varchar NOT NULL, "name" varchar(60), "mail" varchar(64), "homepage" varchar) ENGINE=MyISAM
/home/arun/Desktop/plots2-master/db/migrate/20120101000000_drupal_schema.rb:4:in up' /home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in eval'
/home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in `

'

Caused by:
SQLite3::SQLException: near "ENGINE": syntax error
/home/arun/Desktop/plots2-master/db/migrate/20120101000000_drupal_schema.rb:4:in up' /home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in eval'
/home/arun/.rbenv/versions/2.3.3/bin/ruby_executable_hooks:15:in `

'
Tasks: TOP => db:migrate
(See full trace by running task with --trace)

What did you expect to see that you didn't?

Please show us where to look

https://publiclab.org/ ...

What's your PublicLab.org username?

@arungoel123456

This can help us diagnose the issue:

Browser, version, and operating system

Many bugs are related to these -- please help us track it down and reproduce what you're seeing!


Thank you!

Your help makes Public Lab better! We deeply appreciate your helping refine and improve this site.

To learn how to write really great issues, which increases the chances they'll be resolved, see:

https://publiclab.org/wiki/developers#Contributing+for+non-coders

@jywarren
Copy link
Member

jywarren commented Nov 7, 2018

Hi! I think you should not need to run rake db:migrate when you initially install, but rake db:setup -- see step 7 here: https://github.com/publiclab/plots2/#standard-installation

Also just noting connection to the overall "work together to install plots2" issue here, where others are going through the same steps and may be able to help: #3840

Don't worry, you'll get it!

@jywarren jywarren added the help wanted requires help by anyone willing to contribute label Nov 7, 2018
@shubhscoder
Copy link
Contributor

I think I had faced this same issue while installation. @arungoel123456 try copy pasting the contents of the file I have attached in schema.rb file. It is located in plots2/db/schema.rb
plots_schema.txt

@grvsachdeva
Copy link
Member

Hi @arungoel123456, is your issue resolved?

@coderjolly
Copy link
Member

@arungoel123456 is the issue resolved ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted requires help by anyone willing to contribute installation
Projects
None yet
Development

No branches or pull requests

5 participants