当前位置:网站首页>PostgreSQL stepping on the pit | error: operator does not exist: UUID = character varying
PostgreSQL stepping on the pit | error: operator does not exist: UUID = character varying
2022-07-25 11:18:00 【Panic L】
Business scenario :
stay MyBatis Chinese vs Postgresql Database table data update operation , Report the following error :
Caused by: org.postgresql.util.PSQLException: ERROR: column “data” is of type jsonb but expression is of type character varying
Suggest :You will need to rewrite or cast the expression.
Caused by: org.postgresql.util.PSQLException: ERROR: operator does not exist: uuid = character varying
Suggest :No operator matches the given name and argument types. You might need to add explicit type casts.
reason :
because Postgresql The data type of the database is the same as MySQL atypism , Lead to habitual thinking in MyBatis Write in database sql sentence , Result in an error . The reason is actually the same , Is the data type of the accepted parameter and Postgresql Inconsistency of database .
I am here. uuid and data Namely uuid The type and jsonb type , Here's the picture :
then MyBatis Medium sql as follows :
This is the scene .
resolvent :
Add the corresponding type conversion after each type , Such as uuid The type and jsonb, Add :: type Such a format is sufficient , as follows :
thus , Problem solving !
边栏推荐
- Guys, flick CDC table API, Mysql to MySQL, an application that can
- Esp8266 uses drv8833 drive board to drive N20 motor
- Leetcode 560 prefix and + hash table
- Last week's hot review (7.18-7.24)
- 学习路之PHP--Phpstudy 提示 Mysqld.Exe: Error While Setting Value ‘NO_ENGINE_SUBSTITUTION 错误的解决办法
- 【高并发】如何实现亿级流量下的分布式限流?这些理论你必须掌握!!
- Redis之压缩列表ziplist
- NowCoderTOP1-6——持续更新ing
- 信息熵的定义
- HCIP(13)
猜你喜欢

HCIA experiment (09)

哥廷根大学提出CLIPSeg:一个使用文本和图像prompt能同时作三个分割任务的模型

Learn NLP with Transformer (Chapter 5)

用Unity不会几个插件怎么能行?Unity各类插件及教程推荐

Some usages of beautifulsoup

游戏背包系统,“Inventory Pro插件”,研究学习-----妈妈再也不用担心我不会做背包了(Unity3D)

Ue4.26 source code version black screen problem of client operation when learning Wan independent server

BGP federal experiment

ArcMap无法启动解决方法

HCIP (01)
随机推荐
MySQL advanced statement (I) (there is always someone who will make your life no longer bad)
I, AI doctoral student, online crowdfunding research topic
Hcip experiment (03)
Shell 脚本参数传递时有 \r 换行符问题
Mlx90640 infrared thermal imager temperature measurement module development notes (V)
ESP8266 使用 DRV8833驱动板驱动N20电机
Learn NLP with Transformer (Chapter 4)
BeautifulSoup的一些用法
Digital twin everything can be seen | connecting the real world and digital space
Motivation of enterprises to practice open source
Flask framework - Message flash
Why should the hashcode () method be rewritten when rewriting the equals () method
100W!
MySQL master-slave replication and read-write separation
同事看了我的代码惊呼:居然是这么在Unity中用单例的
shell-第八章练习
SQL语言(一)
让运动自然发生,FITURE打造全新生活方式
【flask高级】结合源码详解flask的运行机制(出入栈)
shell-第五章作业