Removing the constants definitely did take care of the issue on 8.3 (still
same query plan on 8.1). Thanks for your help in getting this resolved, and
sorry again for not including all relevant information on my initial request
On Fri, Apr 4, 2008 at 10:20 PM, Tom Lane <[EMAIL PROTECTED]> wrote:
"Matt Klinker" <[EMAIL PROTECTED]> writes:
> --Joined View:
> CREATE OR REPLACE VIEW directory_listing AS
> SELECT school.id, school.name, school.description, 119075291 AS
> listing_type_fid
>FROM school
> UNION ALL
> SELECT company.id, company.name, company.description, 119074833 AS
> listin
I'm sorry for the "fan-dance", it was not my intention to make it difficult
but actually simpler in leaving out the finer details - lesson learned.
Below you'll find create scripts for all tables and views invlolved. Also
I've included the explain text for both queries when ran on the 8.3 database
"Matt Klinker" <[EMAIL PROTECTED]> writes:
> Sorry for not including this extra bit originally. Below is the explain
> detail from both the query to the view that takes longer and then the query
> directly to the single table that performs quickly.
...
> -> Subquery Scan *SELECT* 1 (cost
Sorry for not including this extra bit originally. Below is the explain
detail from both the query to the view that takes longer and then the query
directly to the single table that performs quickly.
Hash Join (cost=49082.96..1940745.80 rows=11412 width=76)
Hash Cond: (outer.?column1? = inner.
"Matt Klinker" <[EMAIL PROTECTED]> writes:
> I know it's generally requested to include the EXPLAIN text when submitting
> a specific question, but I thought perhaps this was generic enough that
> someone might at least have some suggestions.
You're usually only going to get generic suggestions fr
I'm trying to fine tune this query to return in a reasonable amount of time
and am having difficulties getting the query to run the way I'd like. I
have a couple of semi-related entities that are stored in individual tables,
say, A and B. There is then a view created that pulls together the commo