为 MySQL 存储过程添加默认值为 NULL 的参数 [英] Adding parameters with NULL default value for MySQL stored procedure

查看:44
本文介绍了为 MySQL 存储过程添加默认值为 NULL 的参数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何为 MySQL 存储过程添加默认值为 NULL 的参数?

How can I add parameters with NULL default value for MySQL stored procedure?

推荐答案

根据这个答案 MySQL 不支持 true函数或存储过程中的默认参数".

According to this answer MySQL does not support true 'default parameters' in functions or stored procedures.

同一页面上的这个答案提供了可能适合您的解决方案.

This answer on the same page provides a solution that may work for you.

这篇关于为 MySQL 存储过程添加默认值为 NULL 的参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆