How can I add parameters with NULL default value for MySQL stored procedure?
-
'case when` could be used. Post what you have tried please.bonCodigo– bonCodigo2012-12-30 13:30:36 +00:00Commented Dec 30, 2012 at 13:30
-
I tried to add it but, it does not work, thanxRaed Alsaleh– Raed Alsaleh2012-12-30 13:45:43 +00:00Commented Dec 30, 2012 at 13:45
-
duplicate: stackoverflow.com/questions/12652241/…Patrick Allaert– Patrick Allaert2014-02-06 09:42:10 +00:00Commented Feb 6, 2014 at 9:42
-
possible duplicate of Is it possible to have a default parameter for a mysql stored procedure?Pang– Pang2014-08-21 03:22:47 +00:00Commented Aug 21, 2014 at 3:22
Add a comment
|
2 Answers
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.