Home > Archive > PostgreSQL Administration > September 2005 > data corruption









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author data corruption
Hemapriya

2005-09-28, 8:25 pm

Hi,

I have a query that runs fine for one set of data and
not for another.

In the following query, all the columns used in a
where
clause are indexed. If i use this for the
origindbs('02','05',
'06','07') except '04', it works
fine.
when i look for the data from origindb "04" it just
run for 2 hours.

"select count(*) from qpassextrequest a,request b
where a.requestFK=b.uid and a.origindb='04' and
a.origindb=b.origindb and b.enteredon >='2005-09-28'
and b.enteredon < '2005-09-29'"

What could be the reason.. Can that be a index or data
corruption? If so, rebuiding the index will solve the
problem?

Any hint is appreciated.

Thanks
Priya





____________________
______________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Gourish Singbal

2005-09-30, 3:23 am

priya,
I would suggest do a vacuum full analyze verbose <tablename> on both the
tables.
and than explain analyze <query> command to check if proper indexes are been
used.
regards
gourish singbal
On 9/29/05, Hemapriya <priyam_1121@yahoo.com> wrote:
>
> Hi,
>
> I have a query that runs fine for one set of data and
> not for another.
>
> In the following query, all the columns used in a
> where
> clause are indexed. If i use this for the
> origindbs('02','05',
'06','07') except '04', it works
> fine.
> when i look for the data from origindb "04" it just
> run for 2 hours.
>
> "select count(*) from qpassextrequest a,request b
> where a.requestFK=b.uid and a.origindb='04' and
> a.origindb=b.origindb and b.enteredon >='2005-09-28'
> and b.enteredon < '2005-09-29'"
>
> What could be the reason.. Can that be a index or data
> corruption? If so, rebuiding the index will solve the
> problem?
>
> Any hint is appreciated.
>
> Thanks
> Priya
>
>
>
>
>
> ____________________
______________
> Yahoo! Mail - PC Magazine Editors' Choice 2005
> http://mail.yahoo.com
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Have you searched our list archives?
>
> http://archives.postgresql.org
>




--
Best,
Gourish Singbal

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com