From: Fabio Panizzutti <panizzutti@interlogica.net>
To: 'Manfred Koizar' <mkoi-pg@aon.at>
Cc: pgsql-performance@postgresql.org
Subject: R: R: Query plan on identical tables differs . Why ?
Date: Fri, 14 May 2004 11:22:44 +0200
Message-ID: <001101c43995$03e8b830$3c02020a@ufficio> (raw)
In-Reply-To: <sb57a0dsaijpleaqqf42is4iqp4n7k94qc@email.aon.at>
>>>> Index Scan using pk_storico_misure_2 on storico_misure
>>>>(cost=0.00..1984.64 rows=658 width=21) (actual
>>>time=723.441..1858.107
>>>>rows=835 loops=1)
>>>> Index Cond: ((data_tag > '2004-05-03
>>>00:00:00'::timestamp without
>>>>time zone) AND (data_tag < '2004-05-12 00:00:00'::timestamp without
>>>>time
>>>>zone) AND (tag_id = 37423))
>>>
>>>Either most of the time is spent skipping index tuples in
>>>the data_tag range 2004-05-03 to 2004-05-12 which have
>>>tag_id <> 37423, or getting those 835 rows causes a lot of
>>>disk seeks.
>>>
>>>If the former is true, an index on (tag_id, data_tag) will help.
>>>
Is true , i recreate the indexes making an index on (tag_id, data_tag)
and works fine .
>>>In your first message you wrote:
>>>>fsync = false
>>>
>>>Do this only if you don't care for your data.
>>>
I set it to false , for performance tests .I've a stored procedure that
make about 2000 insert in 2 tables and 2000 delete in another and with
fsync false perfomrmance are 2.000 -3.000 ms (stable) with fsync 3.000
ms to 15.000 ms . I trust in my hardware an O.S so fsync setting is a
big dubt for my production enviroment .
Thanks a lot
Bye
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: panizzutti@interlogica.net, mkoi-pg@aon.at
Subject: Re: R: R: Query plan on identical tables differs . Why ?
In-Reply-To: <001101c43995$03e8b830$3c02020a@ufficio>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox