"Philippe Lang" <philippe.lang@xxxxxxxxxxxxxx> writes: > A small question here: solde_po is an SQL function (not PLPGSQL). Is it > "inlined" in the parent query before the whole query execution plan is > calculated? You should be able to tell that by inspecting the filter conditions in the ANALYZE output. Do you see solde_po(), or its innards? (Or in other words: it depends, and you didn't give us sufficient info to say.) regards, tom lane - Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general