Skip to content

Instantly share code, notes, and snippets.

@joakimk
Created February 25, 2010 14:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joakimk/314591 to your computer and use it in GitHub Desktop.
Save joakimk/314591 to your computer and use it in GitHub Desktop.
Bug?
The SchemaDumper in rails, which is used by rake db:schema:dump expects there to be either a
"pk_and_sequence_for" or "primary_key" on the connection adapter. See line 82:
http://github.com/rails/rails/blob/master/activerecord/lib/active_record/schema_dumper.rb#L82
However... the jdbcmysql adapter does not have either method. The result of this is that running
"jruby -S rake db:schema:dump" will create a schema.rb where every table has :id => false.
http://github.com/nicksieger/activerecord-jdbc-adapter/blob/master/lib/jdbc_adapter/jdbc_mysql.rb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment