Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Use #table_exists? In initialize_schema_migrations_table

#1923

Use table_exists? in #initialize_schema_migrations_table vs hand-rolled tables.detect so that adapter specific implementations can do the leg work of finding out if the schema_info/migration tables really does exist.

Adapters like SQL Server it is common to have a 'dbo.' table name prefix for the user and this causes the migrations to bomb unless we manually specify schema_migrations_table_name to return the correct name.

Reported by Ken Collins · February 9th, 2009 @ 08:31 PM

State: resolved
Milestone: 2.x
Assigned to: Pratik Pratik
Importance: none

Activity

  1. Brennan Dunn
    Brennan Dunn

    Considering this directly impacts me (SQL Server adapter)... +1

    February 9th, 2009 @ 08:34 PM

  2. Brian
    Brian

    +1 - directly impacts

    February 9th, 2009 @ 08:35 PM

  3. Ken Collins
    Ken Collins

    It's not a stop the world bug, but it's the second time this week where I have had to patch hand rolled usage of tables.detect or tables.include vs delegating to the adapter. I like consistency :)

    February 9th, 2009 @ 08:37 PM

  4. nagu
  5. Jonas Schneider
    Jonas Schneider

    if that isn't being patched, i would at least change detect to any? :)

    February 9th, 2009 @ 08:55 PM

  6. Scott Jacobsen
  7. CancelProfileIsBroken
  8. Repository
    Repository
    • State changed from new to resolved

    (from [b193f233908823cccd2f1d5fcb4146787ed8c4ed]) Use table_exists? in #initialize_schema_migrations_table [#1923 Use #table_exists? In initialize_schema_migrations_table state:resolved]

    Signed-off-by: Pratik Naik pratiknaik@gmail.com http://github.com/rails/rails/co...

    May 1st, 2009 @ 02:58 PM