Klairvoyant infosolution's Blog

FasterCSV

john

FasterCSV is intended as a replacement to Ruby‘s standard CSV library.

Installation
1) $ gem install fastercsv
2) add the following to gemfile
gem ‘fastercsv’

code sample

performancecsv=Array.new
FasterCSV.open(“./file.csv”, “w”) do |csv|
@studentdetails.each do | student |
performancecsv.push(“content1″)
………
…..
performancecsv.push(“content2″)
csv << performancecsv
performancecsv.clear
end  #each do
end # FasterCSV

Example code
2) https://github.com/JEG2/faster_csv/tree/master/examples

 

Read more