Bug #73991 Named parameter CALL syntax
Submitted: 21 Sep 2014 10:39
Reporter: Alan Givati Email Updates:
Status: Open Impact on me:
None 
Category:MySQL Server: Stored Routines Severity:S4 (Feature request)
Version: OS:Any
Assigned to: CPU Architecture:Any
Tags: CALL, named parameter, stored procedure, stored routine

[21 Sep 2014 10:39] Alan Givati
Description:
MySQL extended the INSERT syntax with SET, so that the following statement works
INSERT INTO TABLE SET name="Some Dude", age=40;

This is great for tables with many fields, as getting the field & value order right can be a serious headache otherwise.

I propose the same for the CALL syntax. I noticed that Apple supports the same with Swift.  This feature will make code less error-prone and more maintainable.  In an OOP language you can pass objects an achieve the same clarity and safety, but procedural languages lack the ability generally.

How to repeat:
N/A

Suggested fix:
CALL newPerson(name="Some Dude", age=40);
[12 Nov 2023 14:57] Yoni Sade
I suggest the syntax should be:

"CALL newPerson(name=>"Some Dude", age=>40);"

because "=" operator by itself is reserved for assignments or comparisons.