Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them
Date
Msg-id 29762.1350325783@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them  (Bill MacArthur <webmaster@dhs-club.com>)
Responses Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them  (Bill MacArthur <webmaster@dhs-club.com>)
List pgsql-bugs
Bill MacArthur <webmaster@dhs-club.com> writes:
> Tom, in preparation for a test case I created a new schema (testcase) and copied 6 tables to that, including only the
columnssignificant to enable the VIEWs to be created. I took the 3 VIEWs involved and tweaked them into the new schema
(justrenamed to testcase.viewname and referencing testcase.relation). However, when run from in there, the results are
asexpected rather than erroneous. The live data and VIEWs still produce erroneous results. Any clues?? 

Is the query plan the same according to EXPLAIN?

If not, you may have forgotten to vacuum/analyze the new tables, or
forgotten some relevant index.  Or it might be that the total table size
is affecting the plan choice, in which case you need dummy data in the
"irrelevant" columns rather than removing them altogether.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Bill MacArthur
Date:
Subject: Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them
Next
From: Bill MacArthur
Date:
Subject: Re: BUG #7604: adding criteria to a query against a view in 9.2 expands the results instead of constraining them