sql 语句替换 :
select XMLAGG(XMLELEMENT(a, WSODETAILPALINCD || ',')).EXTRACT('//text()').getclobval() as wdpcdss from tablename a
// java 中 用java.sql.Clob 接收
//clob 转字符串
public static String ClobToString(Clob clob) {
String reString = "";
try{
Reader is = clob.getCharacterStream();// 得到流
BufferedReader br = new BufferedReader(is);
String s = br.readLine();
StringBuffer sb = new StringBuffer();
while (s != null) {// 执行循环将字符串全部取出付值给StringBuffer由StringBuffer转成STRING
sb.append(s);
s = br.readLine();
}
reString = sb.toString();
}catch (Exception e){
}
return reString;
}