On Mon, Nov 21, 2011 at 22:15, CC Chen
<lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:
> I upload a file such as EX12345.txt and I want to save the file
> content into database.
>
> The table name I want to call EX12345.(Don''t create by myself)
>
> Does it can work or have other good idea?
Do you mean you want to just save the random textual contents into a
database? Why?
Or is this a CSV file or some other *structured* text that you want to
save into tables, of some format you''ve already determined? Or will
the schema be determined by the structure of the file, which you
intend to parse?
Why do you want to name the table after the file, as opposed to
something more meaningful? Or IS the name meaningful, in some way
that isn''t apparent to us?
If the name is meaningful and the data is structured, methinks it
would probably make more sense to put similar files into the same
table, with a meaningful table name, and with the filenames creating
one or more additional columns.
-Dave
--
LOOKING FOR WORK! What: Ruby (on/off Rails), Python, other modern languages.
Where: Northern Virginia, Washington DC (near Orange Line), and remote work.
See: davearonson.com (main) * codosaur.us (code) * dare2xl.com (excellence).
Specialization is for insects. (Heinlein) - Have Pun, Will Babble! (Aronson)
--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at
groups.google.com/group/rubyonrails-talk?hl=en.