Re: View refuses to work after system reboot

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Jake Newren" <jake_newren(at)yahoo(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: View refuses to work after system reboot
Date: 2001-02-12 17:05:56
Message-ID: 18926.981997556@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Jake Newren" <jake_newren(at)yahoo(dot)com> writes:
> PostgreSQL 7.0.3 installed in the /usr/local/pgsql directory.

> I created a view on my database with the following statement:
> CREATE VIEW wireticket_out AS SELECT wire_tickets.fund_cusip,
> funds.fund_desc, accounts.acct_name, wire_tickets.acct_num,
> wire_tickets.cash_actual, wire_tickets.cash_invest,
> wire_tickets.date_entered FROM wire_tickets INNER JOIN accounts ON
> wire_tickets.acct_num = accounts.acct_num INNER JOIN funds ON
> wire_tickets.fund_cusip = funds.fund_cusip

IIRC, 7.0.* has some rather nasty bugs with nested JOIN clauses, such as
you have here. It'd be safer to express the query with a simple "FROM
wire_tickets, accounts, funds" and put the join conditions in WHERE.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2001-02-12 17:55:52 Re: Table name scope (was Re: Outer joins aren't working with views)
Previous Message Tom Lane 2001-02-12 16:52:07 Re: SELECT with regular pattern '~' delivers wrong output