摘要: 1,通过Hutool.ArrayUtil.zip方法进行处理(缺点,只能保留最短的数组内容) public class Test { public static void main(String[] args) { String chinese = "张三;李四;王五"; String englis 阅读全文
posted @ 2022-06-22 18:01 iullor 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 1,获取具体表的字段相关信息 SELECT col_description (a.attrelid, a.attnum) as comment, format_type (a.atttypid, a.atttypmod) as type, a.attname as name, a.attnotnul 阅读全文
posted @ 2022-05-06 15:43 iullor 阅读(285) 评论(0) 推荐(0) 编辑
摘要: 背景 项目中的Spark程序中需要针对处理的每条数据进行唯一标识,所以使用了Spark 内置的 monotonically_increasing_id() 函数 自动ID生成 monotonically_increasing_id() import static org.apache.spark.s 阅读全文
posted @ 2022-04-26 11:10 iullor 阅读(191) 评论(0) 推荐(0) 编辑
摘要: 1,sparkSQK -jdbc 官方文档 https://spark.apache.org/docs/3.2.1/sql-data-sources-jdbc.html 支持的数据库 DB2 MariaDB MS Sql Oracle PostgreSQL 访问数据库可通过 spark.read() 阅读全文
posted @ 2022-03-29 17:26 iullor 阅读(856) 评论(0) 推荐(0) 编辑
摘要: 一、获取当前时间 1.current_date获取当前日期 2018-04-09 2.current_timestamp/now()获取当前时间 2018-04-09 15:20:49.247 二、从日期时间中提取字段 1.year,month,day/dayofmonth,hour,minute, 阅读全文
posted @ 2022-02-24 09:33 iullor 阅读(1170) 评论(0) 推荐(0) 编辑
摘要: 1,函数类 时间函数 #获取当前时间 select now(); #将时间类型转换为字符串类型 timestamp/date可选 SELECT to_char(now()::timestamp , 'YYYY-MM-DD HH24:MI:ss')::text 阅读全文
posted @ 2022-02-14 16:31 iullor 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 例题来源于 b站灰灰 https://space.bilibili.com/51950540/dynamic?spm_id_from=444.41.0.0 场景1 主线程等待子线程执行完毕后并获取结果而后执行 public class Test { public static void main(S 阅读全文
posted @ 2022-02-07 18:14 iullor 阅读(369) 评论(0) 推荐(0) 编辑
摘要: 1,批量获取数据 jdbc方式优化 Oracle库 connection/datasource 的 isAutoCommit=false JdbcTemplate/PreparedStatement 的 fetchSize=1000 in和exists的场景选取 当查询两个表的大小相当时,用In 和 阅读全文
posted @ 2022-02-07 09:22 iullor 阅读(65) 评论(0) 推荐(0) 编辑
摘要: 转载:https://blog.csdn.net/u010429286/article/details/79022484 自理解: 1,MySQL 其 schema 基本上和 database 等同 表所属在具体的schema下; 在程序中 jdbc:mysql://xxx:3306/数据库名称(s 阅读全文
posted @ 2022-01-05 13:35 iullor 阅读(291) 评论(0) 推荐(0) 编辑
摘要: ###1,将jar包解压到当前目录 jar xvf .\spring-boot-demo.jar 得到以下目录 ###2,修改 BOOT-INF 中的application.yml配置信息 ###3,将修改后的文件替换 jar 包中的文件 jar -uvf .\spring-boot-demo.ja 阅读全文
posted @ 2022-01-04 15:53 iullor 阅读(2012) 评论(0) 推荐(0) 编辑