I would like to write a MySQL stored function that returns multiple rows of data. Is it possible? It seems to be locked in 1 row - cannot even return rows 0 .
for instance
DELIMITER //
create function go ()
RETURNS int
deterministic
NO SQL
BEGIN
return null; - this doesn't return 0 rows! it returns 1 row
- return 0;
END //
DELIMITER;
Returning null from the MySQL stored procedure, although it does not return 0 rows .. it returns 1 row with a null value in it.
Is it possible to return 0 or more than 1 row from a MySQL function, like?
source share