美文网首页
java读取csv文件

java读取csv文件

作者: 泽林呗 | 来源:发表于2017-08-14 16:55 被阅读0次
    public static void main(String[] args) {
            try {
                DataInputStream in = new DataInputStream(new FileInputStream(new File("/home/hadoop/123/16-2016-05-26--2016-05-28.csv-utf8")));
                BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(in,"UTF-8"));
                String stemp;
                while((stemp =bufferedReader.readLine()) != null){
                    System.out.println(stemp);
                }
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
    

    相关文章

      网友评论

          本文标题:java读取csv文件

          本文链接:https://www.haomeiwen.com/subject/ipgurxtx.html