On Wed, Sep 14, 2011 at 6:50 AM, MirrorX wrote:
> any ideas on how i should write to query to use this index? thx in advance
You can do something like:
set enable_seqscan=off;
explain select yourqueryhere;
and see if the plan it comes up with is any better. Use explain
analyze to see how long
On Wed, Sep 14, 2011 at 6:50 AM, MirrorX wrote:
> dear all,
>
> i have a table with (approx) 500.000.000 rows. it has several indexes, one
> of which is a multicolumn index
> for a column that has an id (integer) and a column that has a timestamp. i
> have read in the manual that the multicolumn i
dear all,
i have a table with (approx) 500.000.000 rows. it has several indexes, one
of which is a multicolumn index
for a column that has an id (integer) and a column that has a timestamp. i
have read in the manual that the multicolumn index can be used only if the
clauses of the query are in the
thank you all for your advice. i will try the table partitioning approach to
reduce the size of the tables and to be able to handle them more efficiently
--
View this message in context:
http://postgresql.1045698.n5.nabble.com/cannot-use-multicolumn-index-tp4802634p4806239.html
Sent from the Post
On 14 Září 2011, 17:14, MirrorX wrote:
> thx for the answer.
>
> - What is the problem, i.e. what behaviour you expect?
> - How much data is the table?
> - What portion of it matches the conditions?
> - What is the index definition?
>
> i think in my first post i provided most of these details but
14.09.11 18:14, MirrorX написав(ла):
i think in my first post i provided most of these details but ->
1) what i expect is to be able to understand why the index is not used and
if possibly to use it somehow, or recreate it in a better way
2) the table has 115 GB and about 700 milion rows
3) the r
thx for the answer.
- What is the problem, i.e. what behaviour you expect?
- How much data is the table?
- What portion of it matches the conditions?
- What is the index definition?
i think in my first post i provided most of these details but ->
1) what i expect is to be able to understand why
On 14 Září 2011, 15:09, MirrorX wrote:
> here is the explain analyze output->
> server=# explain analyze select count(*) from temp_by_hour where xid > 100
> and xdate > now() - interval '1 week';
> QUERY
> PLAN
> --
-postgres version -> 8.4.4
-os -> redhat 5.6
-specs ->24 cores, 96GB ram, shared_buffers=32 GB
-postgresql.conf -> i havent made any changes as far as the query tuning
parameters are concerned.
#--
# QUERY TUNING
#-
http://wiki.postgresql.org/wiki/Guide_to_reporting_problems
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
here is the explain analyze output->
server=# explain analyze select count(*) from temp_by_hour where xid > 100
and xdate > now() - interval '1 week';
QUERY
PLAN
11 matches
Mail list logo