Обсуждение: copy command and indexes

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

copy command and indexes

От
"Tim White"
Дата:
When using the copy command to bulk load data, will it update the indexes,
or do you have to explicitly drop and recreate the indexes?

Thanks,

Tim


Re: copy command and indexes

От
Mario Amado Alves
Дата:
On my experience it is better to recreate the indexes.

My experience is trasferring data between several Postgres systems of
different versions---and you know how Postgres versions are
incompatible---, so I have to recreate the indexes (and sometimes the
classes).

In general I dont know if it is at all possible for copy to update the
indexes; I dont think so.

On Tue, 13 Jun 2000, Tim White wrote:

> When using the copy command to bulk load data, will it update the indexes,
> or do you have to explicitly drop and recreate the indexes?
>
> Thanks,
>
> Tim
>

| |,| | | |RuaFranciscoTaborda24RcD 2815-249CharnecaCaparica 351+939354002
|M|A|R|I|O|
|A|M|A|D|O|DepartmentoDeInformaticaFCT/UNL 2825-114 Caparica 351+212958536
|A|L|V|E|S|                                                  fax 212948541
| | | | | |                 maa@di.fct.unl.pt                FCT 212948300


Re: copy command and indexes

От
"Anthony E. Greene"
Дата:
At 14:53 2000-06-13 -0500, Tim White wrote:
>When using the copy command to bulk load data, will it update the indexes,
>or do you have to explicitly drop and recreate the indexes?

Only data tables are loaded. Indexes and other data must be recreated.

 Tony
 --
 Anthony E. Greene <agreene@pobox.com>
 PGP Key: 0x6C94239D/7B3D BD7D 7D91 1B44 BA26  C484 A42A 60DD 6C94 239D
 Linux: The choice of a GNU Generation.

Re: copy command and indexes

От
Bruce Momjian
Дата:
> At 14:53 2000-06-13 -0500, Tim White wrote:
> >When using the copy command to bulk load data, will it update the indexes,
> >or do you have to explicitly drop and recreate the indexes?
>
> Only data tables are loaded. Indexes and other data must be recreated.

Woh.  COPY updates all indexes.

--
  Bruce Momjian                        |  http://www.op.net/~candle
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026