JPA QuerySyntaxException: unexpected token: xxx near

错误:QuerySyntaxException: unexpected token: salaryDate near line 1, column 22

问题:使用的是entityManager.createQuery()方法但是查询却用sql语句,没有使用hql语句

解决:

  1. entityManager.createQuery()方法使用hql语句查询
  2. entityManager.createNativeQuery()方法使用sql语句查询
相关推荐
AI开源软件1 天前
SpringBoot信创项目怎么验收?从数据库迁移到交付证据
postgresql·springboot·达梦·opengauss·信创·企业管理系统
咖啡八杯1 天前
Redis 工具封装:RedisCache 对 Operations 体系的二次封装
java·数据库·redis·缓存·框架·springboot·若依
西凉的悲伤4 天前
Spring Boot 条件装配注解详解
java·springboot·1024程序员节·条件装配
xieliyu.5 天前
【JavaEE进阶】Spring Boot 日志:从 System.out 到 @Slf4j,6 个级别 + 4 类配置一篇讲透
java·spring boot·spring·java-ee·springboot·logback·slf4j
AI开源软件5 天前
SpringBoot + Vue3 人力资源管理系统推荐:组织、档案与移动办公
vue3·springboot·ruoyi·oa系统·移动办公·人力资源管理系统·hrm
AI源码6 天前
社区医院儿童健康信息管理系统
springboot
AI源码6 天前
社区论坛系统
springboot
AI源码7 天前
图书馆借阅管理系统
vue3·springboot
孤狼GPT7 天前
ChatGPT、Codex排查实录:Kafka消费者日志明明显示处理成功,为什么同一条消息还是被重复消费?
kafka·springboot·codex·chatgptplus·chatgptpro
骑着蜗牛撵大象32712 天前
设备监控数据存与查:Spring Boot 接入 TimescaleDB 超表的完整落地
android·spring boot·后端·springboot·时序数据库·es·设备监控