Grzegorz Jaśkiewicz <gryz...@gmail.com> [2009-08-13 14:23]: > On Thu, Aug 13, 2009 at 12:36 PM, Radoslaw Zielinski<ra...@pld-linux.org> > wrote: [...] >> "kandydaci_fk_id_rekordu" FOREIGN KEY (id_rekordu) REFERENCES >> rekordy(id) ON DELETE CASCADE [...] > since you do LEFT JOIN, indeed you can get r.id to be null.
There is a foreign key on this field, and it's the only one used in the JOIN condition. LEFT was only used to demonstrate the issue in a single query. -- Radosław Zieliński <ra...@pld-linux.org>
pgpoKF88MTwR8.pgp
Description: PGP signature