Re: SQL Syntax problem

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: SQL Syntax problem
Дата
Msg-id 9500.1064766205@sss.pgh.pa.us
обсуждение исходный текст
Ответ на SQL Syntax problem  (Doris Bernloehr <bedo7@gmx.net>)
Список pgsql-novice
Doris Bernloehr <bedo7@gmx.net> writes:
> I've got a problem in porting the following select statement from Oracle to
> Postgres, because of the characters after "b.bet_id" and "f.ask_id" in the
> where clause: (+)

Those are outer join markers.  The general idea is that Oracle's

    select ... from a, b where a.f1 = b.f2(+);

transforms to the SQL-standard syntax

    select ... from a left join b on (a.f1 = b.f2);

but I'm very fuzzy on the details beyond that (I'm not totally sure
whether the (+) denotes the left or right side of the join, even).
Anyway try googling for the terms "outer join" and "left join" and
you'll probably find some info on converting Oracle's notation to
standard.

BTW, I believe recent Oracle releases do accept the standard outer
join syntax, so you could consider converting over in general.

            regards, tom lane

В списке pgsql-novice по дате отправления:

Предыдущее
От: Doris Bernloehr
Дата:
Сообщение: SQL Syntax problem
Следующее
От: Oliver Fromme
Дата:
Сообщение: Foreign keys and null