Posts Tagged ‘import’

How to import CSV file in rails

Posted in CSV, Rails, Ruby on Rails, ror on July 18th, 2007 by Satish Chauhan – 2 Comments

How to import CSV file in rails?

The CSV text-file format is a common choice for both import and export when performing data migrations. What if you want to import CSV files within a Rails application?

Here is the code that allow you to upload CSV data onto the MySQL database from the web interface
This code save data direct to database without saving it to temp file

Controller:


View:
your view will look like