On Thu, Jun 20, 2013 at 11:10 AM, Amit Langote <amitlangote09@xxxxxxxxx> wrote: > If this particular function is to be used repeatedly in a single > query, would the cost of having a wrapper function around the original > function be too large? For example, if this function appears in a > WHERE clause against a table containing millions of rows. If your wrapper function is written in SQL and is trivial (eg ignore the third parameter and pass the other two on), the planner should be able to optimize right through it. Best way to find out is with EXPLAIN, which I've been using a good bit lately. The optimizer's pretty smart. ChrisA -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general