Question: what is the difference between procedure and function in postgresql?
Answer: In Postgres, the main functional difference between a function and a stored procedure is that a function returns a result, whereas a stored procedure does not.