Обсуждение: Live records and number of records are differents...

Поиск
Список
Период
Сортировка

Live records and number of records are differents...

От
F T
Дата:
Hello list,

I use PostgreSQL 8.4 and Postgis 1.4.

I use FME to insert 772185 records in a table (multipolygons that represent parcels).

Everything seems fine but...
If I type select count(*), I get the right number of records : 772185 records.

But If I use pgAdmin and have a look in the stats :
- row inserted = 772185 OK fine,
- but the number of live rows is 772308...

I don't understand why the number of live rows and the number of rows is différent...
Any explaination would be very appreciated !
Thanks you

Fabrice



Вложения

Re: Live records and number of records are differents...

От
Grzegorz Jaśkiewicz
Дата:
On Mon, Jun 27, 2011 at 4:12 PM, F T <oukile@gmail.com> wrote:
> Hello list,
>
> I use PostgreSQL 8.4 and Postgis 1.4.
>
> I use FME to insert 772185 records in a table (multipolygons that represent
> parcels).
>
> Everything seems fine but...
> If I type select count(*), I get the right number of records : 772185
> records.
>
> But If I use pgAdmin and have a look in the stats :
> - row inserted = 772185 OK fine,
> - but the number of live rows is 772308...
>
> I don't understand why the number of live rows and the number of rows is
> différent...
> Any explaination would be very appreciated !
> Thanks you
>

PgAdmin uses the statistical information , that's updated by
(auto)vacuum and not running the actual select count(*) I believe.

--
GJ

Re: Live records and number of records are differents...

От
Craig Ringer
Дата:
On 06/27/2011 11:12 PM, F T wrote:

> - but the number of live rows is 772308...

The UI should really say something like "Stats: Estimated number of live
rows: 772308" to indicate more clearly what's going on. At least putting
it under a "Statistics and Estimates" heading/category would help.

--
Craig Ringer