views:

84

answers:

1

I'm returning a complex result of indeterminate size that I will need to handle again and again, so I'm wondering what is a good way to package it?

something like this

loop>>>

@results = { external_id => { :name => name, :type => type } }

or

@results = [ { :external_id => external_id, :name => name, :type => type } ]

or?

end>>>>

and if it ends up being a hash of a hash, do i just use merge?

Thanks

A: 

I ended up with an array of a hash... and it works fine.

holden
Great. Please mark this answer as accepted so your question drops from the unanswered list.
Trevoke