Re: Efficiency in Multiple Queries of Same Table in a PL/PgSQL Function - Mailing list pgsql-sql

From Gary Chambers
Subject Re: Efficiency in Multiple Queries of Same Table in a PL/PgSQL Function
Date
Msg-id 302670f20910191454r4faef8f7m78b5218e6e6a5788@mail.gmail.com
Whole thread Raw
In response to Re: Efficiency in Multiple Queries of Same Table in a PL/PgSQL Function  (Rob Sargent <robjsargent@gmail.com>)
List pgsql-sql
> But if I read the OP correctly the sigma are in fact used additively in each
> row in blah.  "sigma_* = sigma_* +"

I apologize, but I omitted a CASE statement prior to each calculation
of the values.  The coefficients for each calculation change depending
upon which case is valid.  I could probably rewrite it using arrays
and may, in fact, do so to eliminate the two added queries.  Thank you
for your input.

-- Gary Chambers

/* Nothing fancy and nothing Microsoft! */


pgsql-sql by date:

Previous
From: Tom Lane
Date:
Subject: Re: How to order varchar data by word
Next
From: Andrew Hall
Date:
Subject: Dynamic Query