当前位置:网站首页>When MySQL judges that the execution condition is null, it returns 0. Correct parameter count in the call to native function 'isnull',
When MySQL judges that the execution condition is null, it returns 0. Correct parameter count in the call to native function 'isnull',
2022-06-30 12:46:00 【Full stack programmer webmaster】
Pictured , Today, I will test the report statistics , The actual transaction amount needs to be counted , If there is no actual transaction amount on that day , The statistical result will be NULL, I want the query to be NULL when , return 0, But to perform SQL I threw it when I was in bed (1582, "Incorrect parameter count in the call to native function 'ISNULL'") This anomaly
Check the cause
Because mysql Can't recognize ISNULL As a result of , Change to IFNULL That's all right.
SELECT
IFNULL( sum( spu_amount_all ), 0 )
FROM
test_obp_data.data_user_order_goods
WHERE
pay_time BETWEEN '2021-04-29 00:00:00'
AND '2021-04-30 00:00:00'
AND is_refund = 1;Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/100682.html Link to the original text :https://javaforall.cn
边栏推荐
- SuperMap iDesktop 常见倾斜数据处理全流程解析
- [target tracking] |pytracking configuring win to compile prroi_ pool. pyd
- 基于ThinkPHP5封装-tronapi-波场接口-源码无加密-可二开--附接口文档-作者详细指导-2022年6月30日08:45:27
- 浅谈 JMeter 运行原理
- QT MSVC installation and commissioning
- MySQL built-in functions
- 【一天学awk】正则匹配
- 电机控制park变换公式推导
- MySQL判断执行条件为NULL时,返回0,出错问题解决 Incorrect parameter count in the call to native function ‘ISNULL‘,
- FlinkSQL自定义UDATF实现TopN
猜你喜欢

Qt中的数据库使用

Commands for redis basic operations

问卷星问卷抓包分析

Analysis of smart jiangcai login in Jiangxi University of Finance and Economics

数据仓库建设之确定主题域

New function of SuperMap iserver11i -- release and use of legend

Analysis of the whole process of common tilt data processing in SuperMap idesktop

SuperMap 3D SDKs_ Unity plug-in development - connect data services for SQL queries

Browser plays RTSP video based on nodejs

Three ways for flinksql to customize udaf
随机推荐
LeetCode_栈_中等_227.基本计算器 II(不含括号)
Introduction to new features of ES6
Videos are stored in a folder every 100 frames, and pictures are transferred to videos after processing
Redis的配置文件及新数据类型
[qnx hypervisor 2.2 user manual]6.2.3 communication between guest and external
药店管理系统
电机控制Clarke(α/β)等幅值变换推导
rpm2rpm 打包步骤
Redis的基本操作的命令
Docker安装Mysql8和sqlyong连接报错2058的解决方法[随笔记录]
Inner join and outer join of MySQL tables
海思3559萬能平臺搭建:獲取數據幀修改後編碼
Redis-缓存问题
kubeedge的核心理念
[300+ continuous sharing of selected interview questions from large manufacturers] column on interview questions of big data operation and maintenance (II)
c# 怎样能写个sql的解析器
Some commonly used hardware information of the server (constantly updated)
Dataworks synchronizes maxcomputer to sqlserver. Chinese characters become garbled. How can I solve it
Android development interview real question advanced version (with answer analysis)
After the market value evaporated by 65billion yuan, the "mask king" made steady medical treatment and focused on condoms