Ruby1.9ç³» Rails3ã§csvãã¡ã¤ã«ããã¦ã³ãã¼ããã(ã¨ã³ã³ã¼ãåé¡ã«ã対å¿) Rails 3.2.3 ruby 1.9.3 ä¸è¨ã½ã¼ã¹ã§ã²ã¨ã¾ãåãã¦ãã require 'kconv' require 'csv' columns = Person.all file_name = Kconv.kconv("sample.csv", Kconv::SJIS) header = ["åå1", "åå2", "ç»é²æ¥"] #â»1 csv_data = CSV.generate("", {:encoding => 'sjis', :row_sep => "\r\n", :headers => header, :write_headers => true}) do |csv| columns.each do |line| column = [] column << line[:nam
{{#tags}}- {{label}}
{{/tags}}