Re: 335 times faster (!)

Поиск
Список
Период
Сортировка
От Dennis Gearon
Тема Re: 335 times faster (!)
Дата
Msg-id 07ZT76B8E0430883ICCBD0LHIE74PNMG.3e3ec650@cal-lab
обсуждение исходный текст
Ответ на Re: 335 times faster (!)  (Mikael Carneholm <carniz@spray.se>)
Список pgsql-general
My surrogate primary keys will all be INT4's. Seems like it would change something passed in
to an INT4 to match the primary key if that's what the key is.

2/3/2003 11:23:28 AM, Mikael Carneholm <carniz@spray.se> wrote:
<snip>
>Strange...using:
>200178146::bigint
>or
>'200178146'
>..the query is lightning fast. Since the PK column is of integer type, I don't think it's
logical to pass a string-type argument...or am I different than most people on this point? :)
>
>What about third party frameworks (such as Hibernate, eg) - I'm sure they will look at the
column datatype and think: 'Oh, it's an integer...I'll pass an integer argument then', which
will result in unnecessary poor performance.
>
>What's the cause of this behaviour? Why isn't psql (or the backend) converting integer type
arguments into char/string types, if there's this much to gain?
>
>(Sorry for being quite a Pg newbie..have never used Pg for such "heavy" load before)
>
>- Mikael
>
>_____________________________________________________________
>Här börjar internet!
>Skaffa gratis e-mail och gratis internet på http://www.spray.se
>
>Träffa folk från hela Sverige på ett och samma ställe - http://chat.spray.se/
>
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 6: Have you searched our list archives?
>
>http://archives.postgresql.org
>




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

Предыдущее
От: greg@turnstep.com
Дата:
Сообщение: Re: DBI driver and transactions
Следующее
От: Medi Montaseri
Дата:
Сообщение: Re: What is the benefit of schemas?