excel文件保存成csv格式后,jmeter读取后返回的数据乱码

excel文件保存成csv格式后,jmeter读取后返回的数据乱码,见图:

解决方式:

BeanShell PreProcessor和BeanShell PostProcessor下加:
try {  
    vars.put("desc_GB2312",URLEncoder.encode("${desc}","GB2312"));  
} catch (UnsupportedEncodingException e) {  
            // TODO Auto-generated catch block  
            e.printStackTrace();  
}  

编码格式一定要是GB2312!!

之前用的UTF-8不可行啊 o(╯□╰)o

原文地址:https://www.cnblogs.com/by170628/p/7120842.html