From: Nick Hoyle Date: 2009-02-17T00:57:32+09:00 Subject: Re: Parsing CSV file into a database ok thanks thats great, thanks for the quick response. Have you any sample code or examples that you could possible provide me? Thanks for your time Nick Jes炭s Gabriel y Gal叩n wrote: > On Mon, Feb 16, 2009 at 3:25 PM, Nick Hoyle > wrote: >> How would i go about parsing a csv from the web eg yahoo finance stock >> data into my database table called stocks? > > If you have a url to download the csv, you can read it with something > like open-uri. > Then use a CSV library like FasterCSV for csv parsing, and then I > would use a ORM > (Sequel, ActiveRecord or Datamapper come to mind) to create the rows > in your table. > > Hope this helps, > > Jesus. -- Posted via http://www.ruby-forum.com/.