M
M
Maxim Tarabrin2018-03-19 17:33:49
PostgreSQL
Maxim Tarabrin, 2018-03-19 17:33:49

How to get dataset from psql procedure?

The question is, how do I give the combined data at the psql function level. For example, I want to select a couple of fields from one table + another field that is the result of count () of another table and return the whole thing.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Pasechnik Kuzmich, 2018-03-19
@Hivemaster

No problem, return an array, ROWTYPE, RECORD, or arbitrary type from a stored procedure. If there are not many returned values, then OUT parameters can also be used.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question