会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
47Knife
博客园
首页
新随笔
联系
订阅
管理
2025年9月12日
在Spring boot 中使用@master 设置主从数据库
摘要: 基础配置 application.yml spring: datasource: master: url: jdbc:mysql://localhost:3306/master_db username: root password: 123456 driver-class-name: com.mys
阅读全文
posted @ 2025-09-12 00:29 47Knife
阅读(9)
评论(0)
推荐(0)
2021年11月19日
Java 验证两个字段相似度,并输出百分比
摘要: package com.cwjh.utils; public class CompareStrSimUtils { private static int compare(String str, String target, boolean isIgnore) { int d[][]; // 矩阵 i
阅读全文
posted @ 2021-11-19 15:58 47Knife
阅读(433)
评论(0)
推荐(0)
2021年11月2日
413 Request Entity Too Large 错误处理
摘要: 使用String字段接收富文本内容时,提示413错误, 内容字段 2.6M大小, 数据库存储字段类型为LongText,使用了nginx代理,检查后发现是nginx未配置上传文件大小 处理方法: 在nginx http 下添加 后,问题解决
阅读全文
posted @ 2021-11-02 16:13 47Knife
阅读(89)
评论(0)
推荐(0)
2021年3月30日
poi 4.1 XSSFCell类型无法定义的处理方式
摘要: pom文件 <dependency> <groupId>org.apache.poi</groupId> <artifactId>poi</artifactId> <version>4.1.0</version> </dependency> <dependency> <groupId>org.apa
阅读全文
posted @ 2021-03-30 10:06 47Knife
阅读(780)
评论(0)
推荐(0)
2021年3月1日
--initialize specified but the data directory has files in it. Aborting.
摘要: mysql安装时,提示--initialize specified but the data directory has files in it. Aborting. 解决办法: 将data文件夹清空后,重新执行命令
阅读全文
posted @ 2021-03-01 15:31 47Knife
阅读(3154)
评论(0)
推荐(0)
无法定位程序输入点fesetround于动态链接库D:\mysql\bin\mysqld.exe
摘要: 安装mysql 数据库,使用mysqld --initialize 命令时,提示该错误 解决办法: 通过查询是由于缺少安装 Visual C++ 2013 库导致的报错,可以下载安装完成,然后在安装mysql 下载地址:https://www.microsoft.com/zh-CN/download
阅读全文
posted @ 2021-03-01 15:26 47Knife
阅读(1057)
评论(0)
推荐(0)
2020年12月24日
dateFormat 转换 object 日期格式时,年份不正确
摘要: 在使用转换map返回的object 日期格式时,返回的时间少一年,月份和日期都对不上 public static void main(String[] args) throws ParseException { Map<String, Object> map = new HashMap<>(); m
阅读全文
posted @ 2020-12-24 18:36 47Knife
阅读(308)
评论(0)
推荐(0)
使用Java进行图片底片化效果处理
摘要: 使用java代码读取图片,并进行底片化处理 util import java.awt.image.BufferedImage; import java.io.File; import java.util.ArrayList; import java.util.LinkedList; public c
阅读全文
posted @ 2020-12-24 17:44 47Knife
阅读(468)
评论(0)
推荐(0)
2020年12月2日
jdbc数据池配置文件读取
摘要: 1.添加配置文件 jdbc.properties jdbc.userName = root jdbc.password = sepc1234 jdbc.driverClassName = com.mysql.jdbc.Driver jdbc.url = jdbc:mysql://192.168.3.
阅读全文
posted @ 2020-12-02 11:41 47Knife
阅读(132)
评论(0)
推荐(0)
使用HttpClient 获取第三方接口返回结果
摘要: 最近需要在内网环境获取第三方接口提供的数据,只有jdk环境,没有maven环境,所以只能提前提供所需要的jar包 HttpClient 4 使用的jar包 代码 Request request = new Request(); try { //Set the request parameters.
阅读全文
posted @ 2020-12-02 11:37 47Knife
阅读(2309)
评论(0)
推荐(0)
下一页
公告