Java,读取具有UCS-2 Little Endian编码的文件

时间:2019-03-04 18:24:37

标签: java file fileinputstream inputstreamreader

我正在尝试读取具有UCS-2 LE编码的txt文件,下面有以下代码。 ???是我需要的编码变量,但我不确定它应该是什么。

InputStream HostFile = new FileInputStream(Location + FileName);
Reader file = new InputStreamReader(HostFile, Charset.forName(???);
PrintWriter writer = new PrintWriter(outLocation, "UTF-8");

任何想法都将不胜感激。

1 个答案:

答案 0 :(得分:0)

SELECT user_id 
FROM table 
WHERE exception IN (3, 4)
GROUP BY user_id
HAVING COUNT(user_id) = 2