我有以下方法
@Transactional
@JamonMonitored(type = MonitorType.DAO, tag = "name=JpaKeywordDao,method=save")
public void save(List<KeywordEntity> keywords) {
Query updateBidStmt = entityManager.createNativeQuery(SQL_UPDATE_KEYWORD_BIDS_WITH_OPTIONAL_BID);
for (KeywordEntity keyword : keywords) {
updateBidStmt.setParameter(PARAM_INTERNAL_KEYWORD_ID, keyword.getInternalId());
updateBidStmt.setParameter(PARAM_BROAD_MATCH_BID, keyword.getBroadMatchBid() == null ? -1 : keyword.getBroadMatchBid());
updateBidStmt.setParameter(PARAM_CONTENT_MATCH_BID, keyword.getContentMatchBid() == null ? -1 : keyword.getContentMatchBid());
updateBidStmt.setParameter(PARAM_EXACT_MATCH_BID, keyword.getExactMatchBid() == null ? -1 : keyword.getExactMatchBid());
updateBidStmt.setParameter(PARAM_PHRASE_MATCH_BID, keyword.getPhraseMatchBid() == null ? -1 : keyword.getPhraseMatchBid());
updateBidStmt.executeUpdate();
}
}
我想这个方法会执行1的更新1.我想批量执行此操作,因为它会在服务器上加载。
请帮忙。