Skip site navigation (1) Skip section navigation (2)

Outer joins in views

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: Outer joins in views
Date: 2000-12-04 10:58:26
Message-ID: 200012041058.eB4AwQO46212@hub.org (view raw or flat)
Thread:
Lists: pgsql-bugs
Grzegorz M. Mucha (mucher(at)tigana(dot)pl) reports a bug with a severity of 2
The lower the number the more severe it is.

Short Description
Outer joins in views

Long Description
In the 7.1 devel version, the OUTER JOIN statementes are working, but not in VIEWs. I have created the below listed view, and while it allows to be created, any attempt of using it ends with:

ERROR: Internal error: no jointree entry for rel *OLD*


Sample Code
create view ec_recommendations_cats_view as select 
  recs.recommendation_id, 
  COALESCE(cats.category_name,COALESCE(subs.category_name,subsubs.category_name)) AS the_category_name, 
  COALESCE(subs.subcategory_name,subsubs.subcategory_name) AS the_subcategory_name,
  subsubs.subsubcategory_name AS the_subsubcategory_name,
  p.product_name, 
  c.user_class_name
from ec_products p,
  ec_product_recommendations recs LEFT OUTER JOIN
  ec_categories cats on recs.category_id = cats.category_id
  LEFT OUTER JOIN
  ec_subcategories_augmented subs on recs.subcategory_id = subs.subcategory_id
  LEFT OUTER JOIN
  ec_subsubcategories_augmented subsubs on recs.subsubcategory_id = subsubs.subcategory_id
  left outer join
  ec_user_classes c on recs.user_class_id=c.user_class_id
where recs.active_p='t'
and recs.product_id = p.product_id;

No file was uploaded with this report


Responses

pgsql-bugs by date

Next:From: Tom LaneDate: 2000-12-04 14:55:51
Subject: Re: bug with postgresql
Previous:From: Tom LaneDate: 2000-12-03 23:04:25
Subject: Re: alter table rename missing numeric type

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group