- 浏览: 8235 次
- 性别:
- 来自: 北京
最新评论
文章列表
1 第一种
<bean id="configProperties" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
<property name="locations">
<list>
<value>classpath*:config.properties</value>
</lis ...
group by i.sup_seq,i.cp_seq order by i.sup_seq
boolean isWindows = System.getProperty("os.name")
.toLowerCase().startsWith("windows");
System.out.println(System.getProperty("os.name"));
将一个list转换成String org.springframework.util.StringUtils
public static String collectionToDelimitedString(Collection<?> coll, String delim, String prefix, String suffix) {
if (CollectionUtils.isEmpty(coll)) {
return "";
}
StringBuilder sb = new StringBuilder();
Iterator<? ...
for(MallGoodsVO vo : mallGoodsvoList) {
String merchantCatId = vo.getMerchantCatId();
UpdateMerchantCatIdRequestVO updatevo = goodsId2VOMap.get(vo.getGoodsId());
if(updatevo == null) continue;
Stri ...
<!--根据goodsId批量查询MallGoods信息 -->
<select id="findMallGoodsByGoodsIds" resultMap="mallGoodsEntity"
fetchSize="100">
SELECT
<include refid="fields" />
from mall_goods
<where>
<choose>
<when test="goodsIds==n ...
通过接口直接执行sql语句
1 获取接口入参dataSourceName获取NamedParameterJdbcTemplate
public NamedParameterJdbcTemplate getJdbcTemplate(String dataSourceName) {
javax.sql.DataSource dataSource = (DruidDataSource) ApplicationContextManager.get().getBean(dataSourceName);
NamedParameterJdbcTem ...
正则表达式报错 PatternSyntaxException Unclosed group near index 1
public static void main(String[] args) throws Exception {
System.out.println("(abc)".replaceAll("(", ""));
}
从网上查找类似问题,找到了解决方法,解决方法很简单,对于字符'(',使用 \\( 或 [(] 即可。