D
D
Denis Lvov2021-06-07 13:22:44
PostgreSQL
Denis Lvov, 2021-06-07 13:22:44

How to sequentially call a custom function with a new parameter (postresql)?

The problem is the following.
I wrote my own function, it takes 1 parameter as input,

I want to do something like

SELECT
DISTINCT C.city_nm
,N.Name
FROM city C
INNER JOIN (SELECT city_nm, name FROM my_func(C.city_nm)) N
USING (city_nm)


Naturally, nothing comes out of the output
HINT: There is an entry for table "C", but it cannot be referenced from this part of the query.

How can you organize a sequential function call with a unique list of parameters?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question