📄 updateprize.java
字号:
package com.blogool.export;
import java.sql.Connection;
public class UpdatePrize {
public static void main(String[] args) {
Connection conn = DBUtil.getConnection();
for (int i = 20239; i <= 25283; i ++) {
String sql = "update product set prize1 = prize1 * " + (0.75 + Math.random() / 20) + " where id = " + i;
DBUtil.update(conn, sql, new Object[] {});
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -