Hello,

I'm trying to set up an ETL process to load some data from various
data sources into a data warehouse oriented database using Sequel.
I'm trying to dynamically construct the DB.create_table! block, but
the "field_defs" variable I have is out of scope and I can't access it
within the create table block.

Any suggestion how I can do this?

DB.create_table!(table) do
  primary_key :id
  field_defs.each do |field_def|
    column(field_def["field_name"], field_def["type"], :index =>
field_def["indexed"])
  end
end

Thanks,

Michael
-- 
http://codeconnoisseur.org

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sequel-talk?hl=en.

Reply via email to