Re: the results from a query - question

Поиск
Список
Период
Сортировка
От Ian Barwick
Тема Re: the results from a query - question
Дата
Msg-id 200304021628.23868.barwick@gmx.net
обсуждение исходный текст
Ответ на the results from a query - question  ("Johnson, Shaunn" <SJohnson6@bcbsm.com>)
Список pgsql-general
On Wednesday 02 April 2003 16:00, Johnson, Shaunn wrote:
> Running PostgreSQL 7.2.1 on RedHat Linux 7.2.
>
> Question - I'm looking at one of the users query
>
> [snip query]
> explain
> select *
> -- INTO dev_gm_er_prof01
> FROM
>   db2_gm_reg_prof_01
> WHERE
> db2_gm_reg_prof_01.place_of_service = 2 and
> db2_gm_reg_prof_01.diagnosis_cd not like '29%' and
> db2_gm_reg_prof_01.diagnosis_cd  not like '30%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '310%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '311%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '312%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '313%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '314%' and
> db2_gm_reg_prof_01.diagnosis_cd not like '315%' and
> db2_pos_reg_prof_01.diagnosis_cd not like '316%'
> --ORDER BY
> --  db2_gm_reg_prof_01.contract_num ASC;
>
> [/snip query]

From this query, db2_pos_reg_prof_01 does not seem to be joined
explicity to db2_gm_reg_prof_01. This may be producing more rows than
you want (cartesian join)...

Ian Barwick
barwick@gmx.net


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

Предыдущее
От: "Johnson, Shaunn"
Дата:
Сообщение: Re: the results from a query - question
Следующее
От: Tom Lane
Дата:
Сообщение: Re: the results from a query - question