[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Create a table for a new migration

Zangief Ief

7/20/2008 11:52:00 AM

Hi everybody,

I had generated some migrations files such as
"20080719111013_create_countries.rb" for "countries" table :

class CreateCountries < ActiveRecord::Migration
def self.up
create_table :countries, :force => true do |t|
t.string :name, :null => false, :limit => 80
end
end

def self.down
drop_table :countries
end
end

And now I would like to generate a new file migration for
"arts_countries" table. But I don't know how to write the nice command
with the right convention because this table is composed by arts and
countries tables (so there isn't any model)...

Thanks for every ideas.
Zhang'
--
Posted via http://www.ruby-....

1 Answer

Zangief Ief

7/20/2008 12:20:00 PM

0

Oops! sorry. I thought I was in a Rails forum. Sorry again.
--
Posted via http://www.ruby-....