I have a function that I will be running 10-50 times at once:
importsitechanges(33, 209703, 'Store Name', 'Addr', 'city', 'state', 'zip', 'phone')
This function that I made returns the number of changes made as a string.
When I run many of them at once in pgadmin, I only get the return string from the last one:
SELECT * FROM importsitechanges(33, 321344, 'Store Name', 'Addr', 'city', 'state', 'zip', 'phone');
SELECT * FROM importsitechanges(32, 209703, 'Store Name', 'Addr', 'city', 'state', 'zip', 'phone');
...
How can I get the return strings from all of these functions?
UNION ALL
the single calls. This way you'll get a table, one row for each execution.SELECT * FROM importsitechanges(33, 321344, 'Store Name', 'Addr', 'city', 'state', 'zip', 'phone') UNION ALL SELECT * FROM importsitechanges(32, 209703, 'Store Name', 'Addr', 'city', 'state', 'zip', 'phone') UNION ALL ...