Hi all,
Is it possible to do a db name change during the course of
the project and then propagate the effect all across the project?
E.g. I started
of doing a sample program with db name as “tests”. As the project evolved I decided
to change its name to “biodatas”.
" create_table “tests”, :force => true do |t|
t.column “name”, :string, :limit => 45, :default => “”, :null => false
t.column "class", :integer, :limit => 10, :default => 0, :null => false
t.column "address", :string, :limit => 45, :default => "", :null => false
t.column
“city”, :string, :limit => 45, :default => “”, :null => false
end
"
Cherian Thomas wrote:
Is it possible to do a db name change during the course of the
project and then propagate the effect all across the project?
E.g. I started of doing a sample program with db name as
"tests". As the project evolved I decided to change its name to "biodatas".
Making a migration with
rename_table "tests", "biodatas"
will rename the table for you.
You'll have to search-and-replace in order to change mentions of Test
to Biodata in your code, unless you're using an IDE that can do this
for you.
Chris
i get u on migration.
and about ide. i use rad rails of eclipse.pretty much new to it. does it allow this kind of refactoring?