How RoR works with table created on fly

Hi, all
I’ve trying to look for answers for my problem but so far couldn’t
find one, hopefully someone can tell me what to do. In my application,
I
have to let user can create new table, and they can add or
delete columns. The tables they created, I can’t do things that RoR
usually
can do, like ( Table.find_by_id ), because they are not modeled. Is
there any
way that I can setup model for a table that user created on fly?
Thanks for your help!

The code I used to create table is like this:
ActiveRecord::Base.connection.create_table :table_name do |t|
t.column :name, :string
end

You might find Dr Nic’s magic models to be of interest: http://
magicmodels.rubyforge.org/dr_nic_magic_models/

Fred

Nic’s magic is amazing.
Thank you so much, Fred!

On Oct 12, 10:44 am, Frederick C. [email protected]