Re: Test Database fails to initialize

Frederick Cheung
2008-04-22T17:54:12Z

On 22 Apr 2008, at 18:27, CapnRegex wrote:
>
> Model.connection.execute(''CREATE INDEX index_name ON table_name
> ( field1, field2, text_field(20) )'')
>
> however, rails records that in the schema.rb as
>
> add_index "table",
["field1","field2","text_field"], :name =>
> "index_name"
>
> which fails.
>
> I don''t want to eliminate the index, as it gives me a considerable
> speed increase when looking for an exact match in the text_field..

Switch from using the ruby schema dumper to the sql one (it''s an
option in environment.rb)