> I am creating a csv file with fastercsv.
>
> require 'fastercsv'
> FasterCSV.open("file.csv", "w") do |csv|
> csv << [45678, 45678, "stringa"]
> end
>
> I would also print the last cell in quotation marks. Is there anyone who
> can help me?
You may want :force_quotes...
:force_quotes: When set to a true value, FasterCSV will quote all CSV fields
it creates.
FasterCSV.open("file.csv", "w", :force_quotes => true).....
That may also quote the numbers, I don't recall...
-philip
--
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 [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.