Forum: Ruby on Rails Curious about new (ActiveRecord::Base)

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
lisa umeda (Guest)
on 2006-06-12 23:02
Because the documentation isn't clear (at least to me)...

I have a Logfile model that has corresponding fields in MySql.
The main ones are id, fileName, and content type.  However, I can pass a
File object to a new Logfile and have handlers that I created in the
Logfile class extract the data.  However, the documentation states
"...you canĂ¢??t have attributes that arenĂ¢??t part of the table columns."
Why is this possible (this isn't really a problem, but I just wanted to
know)?

The above method works for individual files.

My problem is this - I would like to have rubyzip exctract files to
create new Logfiles.  My current method is to iterate through the
ZipFile using foreach, but this yields ZipEntries.  Is there a way to
extract this as a Tempfile until its final destination is determined
using my above-mentioned handlers?  Or is there a better way to go about
this?

Please point me to the proper docs and I'll do my best to figure it out.
Thank you!
This topic is locked and can not be replied to.