Re: Poor Query

Поиск
Список
Период
Сортировка
От Pierre-Frédéric Caillaud
Тема Re: Poor Query
Дата
Msg-id opsilgs8b4cq72hf@musicbox
обсуждение исходный текст
Ответ на Re: Poor Query  (Pallav Kalva <pkalva@deg.cc>)
Ответы Re: Poor Query  (Pallav Kalva <pkalva@deg.cc>)
Список pgsql-performance

    Just wanted to know the selectivity of the accountnumber and
routingNumber columns.
    I shoulda written :

>>     How many rows do the following queries return :
    One or few at most, or a lot ?
>>
>> select userID
>>              from bankaccount
>>              WHERE accountnumber = '12345678'
>>
>> select userID
>>           from bankaccount
>>           WHERE routingNumber = '12345678'
>>
>>     Can you post EXPLAIN ANALYZE for these two queries ?
>>     Regards.
>>
> Thanks! for the quick reply. It should usually return just one account
> for that user so its only one record. Actually userid column doesnt
> exist on bankaccount table it exists only on the user table and it is
> joined with bankaccountid column, if i run this query separately i
> wouldnt able to run it .
>
>




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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Config Check
Следующее
От: Pallav Kalva
Дата:
Сообщение: Re: Poor Query