Обсуждение: Ayuda sobre Indices
Buen Dia. Por favor si saben como, me gustaria saber como puedo eliminar un indice PERO SOLO si este existe. Como valido si existe o no el indice para luego eliminarlo ?? Gracias. ----------- Please, i need drop index but ONLY and ONLY this exist index. Thanks.
Si quieres escribir en español, por favor, escribe a
pgsql-es-ayuda@postgresql.org
esta es una lista en ingles. Tu respuesta abajo...
On 1/25/07, julio.caicedo@genome-it.com <julio.caicedo@genome-it.com> wrote:
> Buen Dia.
>
> Por favor si saben como, me gustaria saber como puedo eliminar un indice
> PERO SOLO si este existe. Como valido si existe o no el indice para luego
> eliminarlo ??
>
> Gracias.
>
from 8.2 you can do:
DROP INDEX IF EXISTS name ;
--
regards,
Jaime Casanova
"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs and the universe trying
to produce bigger and better idiots.
So far, the universe is winning."
Richard Cook
If the index exists, you will find it in pg_indexes. Mark On Jan 25, 5:29 pm, julio.caic...@genome-it.com wrote: > Buen Dia. > > Por favor si saben como, me gustaria saber como puedo eliminar un indice > PERO SOLO si este existe. Como valido si existe o no el indice para luego > eliminarlo ?? > > Gracias. > > ----------- > Please, i need drop index but ONLY and ONLY this exist index. Thanks. > > ---------------------------(end of broadcast)--------------------------- > TIP 1: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majord...@postgresql.org so that your > message can get through to the mailing list cleanly