Re: Need help to decide Mysql vs Postgres

От: Alvaro Herrera
Тема: Re: Need help to decide Mysql vs Postgres
Дата: ,
Msg-id: 20050606161537.GB9595@surnet.cl
(см: обсуждение, исходный текст)
Ответ на: Re: Need help to decide Mysql vs Postgres  (Amit V Shah)
Список: pgsql-performance

Скрыть дерево обсуждения

Need help to decide Mysql vs Postgres  (Amit V Shah, )
 Re: Need help to decide Mysql vs Postgres  ("Joshua D. Drake", )
 Re: Need help to decide Mysql vs Postgres  (Amit V Shah, )
  Re: Need help to decide Mysql vs Postgres  ("Joel Fradkin", )
  Re: Need help to decide Mysql vs Postgres  ("Joshua D. Drake", )
   Re: Need help to decide Mysql vs Postgres  (Philip Hallstrom, )
 Re: Need help to decide Mysql vs Postgres  (Josh Berkus, )
 Re: Need help to decide Mysql vs Postgres  (Amit V Shah, )
  Re: Need help to decide Mysql vs Postgres  ("Steinar H. Gunderson", )
  Re: Need help to decide Mysql vs Postgres  (Josh Berkus, )
 Re: Need help to decide Mysql vs Postgres  (PFC, )
 Re: Need help to decide Mysql vs Postgres  ( (), )
 Re: Need help to decide Mysql vs Postgres  (Bill Ewing, )
  Re: Need help to decide Mysql vs Postgres  (Christopher Kings-Lynne, )
  Re: Need help to decide Mysql vs Postgres  (PFC, )
 Re: Need help to decide Mysql vs Postgres  (Jeffrey Tenny, )
  Re: Need help to decide Mysql vs Postgres  (Tobias Brox, )
   Re: Need help to decide Mysql vs Postgres  (Michael Fuhr, )
 Re: Need help to decide Mysql vs Postgres  (Amit V Shah, )
  Re: Need help to decide Mysql vs Postgres  (Alvaro Herrera, )
  Re: Need help to decide Mysql vs Postgres  (Rod Taylor, )
  Re: Need help to decide Mysql vs Postgres  (PFC, )
 Re: Need help to decide Mysql vs Postgres  (Amit V Shah, )
  Re: Need help to decide Mysql vs Postgres  (Christopher Browne, )
   Re: Need help to decide Mysql vs Postgres  (Ron Mayer, )
    Re: Need help to decide Mysql vs Postgres  (Tom Lane, )
  Re: Need help to decide Mysql vs Postgres  (PFC, )
   Re: Need help to decide Mysql vs Postgres  (Jan Wieck, )
    Re: Need help to decide Mysql vs Postgres  ("Joel Fradkin", )
     Re: Need help to decide Mysql vs Postgres  (PFC, )
      Re: Need help to decide Mysql vs Postgres  (Enrico Weigelt, )
       Re: Need help to decide Mysql vs Postgres  (Mark Lewis, )
        Re: Need help to decide Mysql vs Postgres  (Moises Alberto Lindo Gutarra, )

On Mon, Jun 06, 2005 at 12:00:08PM -0400, Amit V Shah wrote:

> I made a schema with 5 tables. I have a master data table with foreign keys
> pointing to other 4 tables. Master data table has around 4 million records.
> When I run a select joining it with the baby tables,
>
> postgres -> returns results in 2.8 seconds
> mysql -> takes around 16 seconds !!!! (This is with myisam ... with innodb
> it takes 220 seconds)

PostgreSQL has an excellent query optimizer, so if you get a much better
execution time than MySQL in complex queries this isn't at all unexpected.

I assume the MySQL guys would tell you to rewrite the queries in certain
ways to make it go faster (just like the Postgres guys tell people to
rewrite certain things when they hit Postgres limitations.)

--
Alvaro Herrera (<alvherre[a]surnet.cl>)
"I would rather have GNU than GNOT."  (ccchips, lwn.net/Articles/37595/)


В списке pgsql-performance по дате сообщения:

От: Tom Lane
Дата:
Сообщение: Re: Postgresql on an AMD64 machine
От: Mark Rinaudo
Дата:
Сообщение: Re: Postgresql on an AMD64 machine