logo
publist
写文章

简介

该用户还未填写简介

擅长的技术栈

可提供的服务

暂无可提供的服务

idea 设置快捷键注释自动缩进功能

问题描述:在使用idea过程中,快捷键注释无疑是经常使用的一个功能,然而通过快捷键注释时,效果往往是这样的????// ModelAndView : 模型和视图ModelAndView modelAndView = new ModelAndView();//=========请忽视代码内容,自动注释效果主要看这里=============...

#java
[ERR] 1273 - Unknown collation: ‘utf8mb4_0900_ai_ci‘

错误描述:在将MySQL一个数据库的表,都复制到MariaDB数据库中时,报错[ERR] 1273 - Unknown collation: 'utf8mb4_0900_ai_ci'。原因分析:通过查询,得到的解释是生成转储文件的数据库版本为8.0,要导入sql文件的数据库版本为5.6,因为是高版本导入到低版本,引起1273错误。然而,当我查看MySQL数据库时,发现字符集就是utf8,排序规则也

#数据库#mysql#sql +2
springboot报错:Failed to parse configuration class XXX…non-compatible bean definition of same name XXX

错误描述:在旧项目的基础上,添加了新的功能,启动项目进行测试时,报如下错误????org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [com.vinux.VitapolloRoleBizApplication]; nested exception i

#java#spring boot
后端返回前端的值为Null时的几种处理方式

问题描述:接手了公司一个不知道转了几手的老项目,在与前端联调的时候,发现有很多返回数据,都是用实体类来接收返回的,而这其中,甚至有的实体类属性有几十个,但实际需要返回的参数却只需几个,于是就出现了一大长串 null 的情况,简直不能忍!!!// 原本的返回代码示例,来感受一下这种源自内心的颤抖吧{"id": 1,"loginId": 123456,"loginName":

#java#spring
Bean named 'xxx' is expected to be of type 'xxx' but was actually of type 'com.sun.proxy.$Proxy13

问题描述:在整合mybatis-spring实现事务时,测试出现如下错误????Bean named 'userMapper' is expected to be of type 'com.cheng.mapper.UserMapperImpl' but was actually of type 'com.sun.proxy.$Proxy13'翻译:名为“userMapper”的Bean应为’c.

#mybatis#bug
Mybatis

Mybatis环境:JDK 1.8Mysql 5.7maven 3.6.1IDEA回顾:JDBCMysqlJava基础MavenJunit框架:配置文件。最好的方式:看官网文档https://mybatis.org/mybatis-3/1、简介1.1 什么是 MyBatis?MyBatis 是一款优秀的持久层框架。它支持自定义 SQL、存储过程以及高级映...

#java#mybatis#数据库 +1
JSP

JSP1、什么是JSPJava Server Pages:Java服务端页面,也和 Servlet 一样,用于动态 web 技术。最大的特点:写 JSP 就像在写 HTML区别:HTML 只给用户提供静态的数据JSP 页面中可以嵌入 Java 代码,为用户提供动态数据2、JSP 原理思路:JSP 到底怎么执行的?代码层面没有任何问题服务器内部工作tomca...

#java
org.apache.ibatis.binding.BindingException: Type interface xxx is not known to the MapperRegistry.

问题描述:在使用mybatis的过程中,出现了如下错误提示????org.apache.ibatis.binding.BindingException: Type interface com.cheng.dao.UserDao is not known to the MapperRegistry.翻译:MapperRegistry不知道类型接口com.cheng.dao.UserDao。排错:..

#maven#mybatis#java +1
到底了