On Thu, Nov 15, 2012 at 1:34 PM, Chitra Creta wrote:
> Thanks for your example Chris. I will look into it as a long-term solution.
>
> Partitioning tables as a strategy worked very well indeed. This will be my
> short/medium term solution.
>
> Another strategy that I would like to evaluate as a s
On Wed, Nov 14, 2012 at 10:12 AM, Tianyin Xu wrote:
> Hi, Postgresql,
>
> I want to understand how the query optimizers affect the output of the
> window functions.
>
> For example, set "cpu_tuple_cost = 50" in postgresql.conf and start the
> server, I apply the regress test (make installcheck).
On Fri, Nov 9, 2012 at 9:21 PM, George Weaver wrote:
> **
> Hi Everyone,
>
> I have a view made up of a local query unioned with a view comprised of a
> dblink query.
>
> If the dblink query cannot establish a connection, I get the "could not
> connect to server" error and the whole view fails.
>
Hello,
try something like
WITH lastreceipt as
(SELECT DISTINCT ON (acc.cname) acc.cname, acc.date, acc.amount
FROM accounts acc
ORDER BY acc.date DESC)
UPDATE customer_master
SET lastreceiptdate = lr.date
lastreceiptamt = lr.amount
FROM lastreceipt lr
WHERE cname = lr.cname
(Haven't tested