Is it possible to pass the results of a postgres request as input to another function?
As a very far-fetched example, let's say I have one request, for example
SELECT id, name FROM users LIMIT 50
and I want to create a my_function function that takes the result set of the first query and returns the minimum identifier. Is this possible in pl / pgsql?
SELECT my_function(SELECT id, name FROM Users LIMIT 50);
Ben hamner
source share