摘要:
1、实现效果 浏览器地址栏输入地址http://192.168.17.128/edu/a.html,负载均衡效果,平均在8080和8081端口中 2、准备工作 1)准备两台tomcat服务器,一台8080,一台8081 2)在两台tomcat里面的webapps目录中,创建名称是edu文件夹,在文件 阅读全文
摘要:
首先得到两个需要进行对比的参数: BigDecimal a1=new BigDecimal(20); BigDecimal a2=new BigDecimal(20);1.使用equals()方法 if(a1.equals(a2)){ System.out.println("相等"); }else{ 阅读全文
摘要:
1,调取接口代码 RestTemplate restTemplate=new RestTemplate();HttpHeaders headers=new HttpHeaders();MultiValueMap<String,String> map=new LinkedMultiValueMap<> 阅读全文
摘要:
from on join where group by having select distinct union order by 注:根据以上结果可制定SQL优化方案 阅读全文
摘要:
Java BigDecimal类型的 加减乘除运算普通的数据运算不一样,需要调用相应的方法: 加法:add 减法:subtract 乘法:multiply 除法:divide 可参考下面代码: BigDecimal num1= new BigDecimal("2"); BigDecimal num2 阅读全文
摘要:
1,所需数据 工商银行 1236545878965874562 建设银行 1236545698745632145 2,html <table border="1"> <thead> <tr> <td>开户行</td> <td>账号</td> </tr> </thead> <tbody id="myT 阅读全文
摘要:
1,拿到需要输出的对象集合 List<Object> bankinfos= new ArrayList<>();bankinfos.add(new Object("bank":"工商银行,"account”:"123654569874563215"));bankinfos.add(new Objec 阅读全文
摘要:
1,varchar转int cast( varchar as integer ) 2,varchar 转 double cast( varchar as float) 注:括号中的 “varchar” 便是要转化的数据表中的字段 阅读全文
摘要:
使用下列方式即可: value like CONCAT(CONCAT('%', #{value}), '%') 前一个value对应数据库字段,后一个value对应用户数据的查询条件注:1、可查出含有value的所有数据 2、“_”可替换“%”代表一个字符(汉字或数字) 阅读全文
摘要:
import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; //拿到需要转化的json字符串String jsonString="[{\"input4\":\"40\",\"input3\":\"30\ 阅读全文