I have spanish data in my oracle database (charectorset AL32UTF8). I am reading the data from the db and writing into a csv
file, and from csv
I am reading the data again and doing some operation. But in the csv
file it is displaying junk values.
I did the same thing on linux and it is working correctly.
public class T {
CSVWriter out = null;
private void write(String[] values) throws IOException {
out.writeNext(values);
}
public static void main(String[] args) throws IOException {
File f = new File("s.csv");
FileOutputStream os = new FileOutputStream(f, false);
CSVWriter out = new CSVWriter(
new BufferedWriter(
new OutputStreamWriter(
os, "UTF-8")));
}
}