[Pgsql-ayuda] AYUDA !!!

Ricardo Colín rcolin@ife.org.mx
27 Nov 2002 12:05:49 -0600


--=-iwlh3UXSAevths4Z/w+p
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

SALUDOS.

NECESITO SI ALGUIEN ME PUEDE ORIENTAR COMO CORREGIR EL SIGUIENTE ERROR
QUE ME APARECE EN POSTGRES.


java.sql.SQLException: IOError while reading from backend:
java.io.IOException

REGULARMENTE ME APARECE EL MENSAJE " intente la operacion m=E1s tarde ",
LO QUE HAGO ES REINICIAR, PERO ES UN ERROR QUE ES CONSTANTE

LA VERSION QUE TENGO DE POSTGRES ES : el 6..5=20

De antemano muchas gracias.

Attn.
---
Ricardo Col=EDn



El mi=E9, 27-11-2002 a las 11:48,
pgsql-ayuda-request@tlali.iztacala.unam.mx escribi=F3:

    Send Pgsql-ayuda mailing list submissions to
    	pgsql-ayuda@tlali.iztacala.unam.mx
   =20
    To subscribe or unsubscribe via the World Wide Web, visit
    	http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda
    or, via email, send a message with subject or body 'help' to
    	pgsql-ayuda-request@tlali.iztacala.unam.mx
   =20
    You can reach the person managing the list at
    	pgsql-ayuda-admin@tlali.iztacala.unam.mx
   =20
    When replying, please edit your Subject line so it is more specific
    than "Re: Contents of Pgsql-ayuda digest..."
   =20
   =20
    Today's Topics:
   =20
       1. Re: Uso de postgres desde PHP (Edgar Raul Acosta =3D?iso-8859-1?q=
?Villase=3DF1or?=3D)
       2. =3D?iso-8859-1?Q?=3DBFC=3DF3mo_se_come_esto=3D3F?=3D (=3D?iso-885=
9-1?Q?Antonio_M=3DE1rmol_Albert?=3D)
       3. =3D?iso-8859-1?Q?RE:_=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come_=
esto=3D3F?=3D (=3D?iso-8859-1?Q?Adri=3DE1n_Caldeiro?=3D)
       4. Re: Como veo todos los campos de una Base de datos (Jaime N. Char=
les =3D?ISO-8859-1?Q?Trevi=3DF1o?=3D)
       5. Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come_=
esto=3D3F?=3D (=3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D)
       6. Re: Re: [Pgsql-ayuda] =3D?iso-8859-1?q?=3DBFC=3DF3mo=3D20se=3D20c=
ome?=3D esto? (=3D?iso-8859-1?q?V=3DEDctor=3D20R=3D2E?=3D Ruiz)
       7. =3D?iso-8859-1?Q?Re:_=3D5BPgsql-ayuda=3D5D_Re:_=3D5BPgsql-ayuda=
=3D5D_=3DBFC=3DF3mo_se_c?=3D
           =3D?iso-8859-1?Q?ome_esto=3D3F?=3D (J. Mario Oroz)
       8. Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_Re:_=3D5BPgsql-ayuda=
=3D5D_=3DBFC=3DF3mo_se_come?=3D
           =3D?iso-8859-1?Q?_esto=3D3F?=3D (=3D?iso-8859-1?Q?Antonio_M=3DE1=
rmol_Albert?=3D)
       9. Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come_=
esto=3D3F?=3D (=3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D)
      10. Re: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =3D?iso-8859-1?q?=3DBFC=
=3DF3mo=3D20se=3D20come?=3D esto? (=3D?iso-8859-1?q?V=3DEDctor=3D20R=3D2E?=
=3D Ruiz)
      11. =3D?iso-8859-1?q?=3DBFC=3DF3mo=3D20se=3D20come?=3D esto? (Cesar V=
illanueva)
      12. =3D?iso-8859-1?Q?Re:_=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come_=
esto=3D3F?=3D (J. Mario Oroz)
      13. Re: =3D?iso-8859-1?q?=3DBFC=3DF3mo?=3D se come esto? (Manuel Suga=
wara)
      14. Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come_=
esto=3D3F?=3D (=3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D)
   =20
    --__--__--
   =20
    Message: 1
    From: Edgar Raul Acosta =3D?iso-8859-1?q?Villase=3DF1or?=3D <edgar@tlah=
ui.posgrado.unam.mx>
    To: Pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: Re: [Pgsql-ayuda] Uso de postgres desde PHP
    Date: Wed, 27 Nov 2002 08:55:55 -0600
   =20
    Hola,
   =20
    =3D09Por los datos que proporcionas, me parece que tienes que revisar(m=
odif=3D
    icar)=3D20
    el archivo data/pg_hba en el directorio de trabajo de postgresql. En es=
e=3D20
    archivo est=3DE1n los permisos de acceso a la base de datos, as=3DED qu=
e esa=3D20
    configuraci=3DF3n debe corresponder a la seguridad que desees, el mismo=
 arc=3D
    hivo=3D20
    te explica c=3DF3mo modificarlo.
   =20
    =3D09Adem=3DE1s tienes que estar seguro que el servicio de postgres ace=
pta co=3D
    nexiones=3D20
    por red y en el puerto 5432.
   =20
    =3D09Saludos
   =20
    =3D09=3D09Edgar Acosta
   =20
    El Mi=3DE9 27 Nov 2002 06:30, Adri=3DE1n Caldeiro escribi=3DF3:
    > Hola a todos.
    >
    >     Estoy empezando con postgres, lo instale en Debian Woody, lei la
    > documentacion e incluso busque informaci=3DF3n en Internet, pero no e=
ncue=3D
    nto
    > como solucionar el tema de como acceder a postgres desde PHP.
    >
    >      El tema es que desde la linea de comando, puedo acceder, crear b=
as=3D
    es
    > de datos, insertar, etc ..., pero, si lo intento hacer desde PHP me d=
a
    > varios errores, si no le pongo usuario me dice "www-data no existe en=
 e=3D
    sta
    > pagina", si le pongo como usurario postgres "me dice que no lo puede
    > validar" (el usuario postgres no tiene password), si le coloco un pas=
sw=3D
    ord
    > y lo quiero usar con dicho password tambien me da problemas.
    >
    >     Alguno tiene idea cual puede ser la soluci=3DF3n, desde ya muchas=
 gra=3D
    cias.
    >
    > Saludos Adri=3DE1n.
    >
    >
    >
    > _______________________________________________
    > Pgsql-ayuda mailing list
    > Pgsql-ayuda@tlali.iztacala.unam.mx
    > http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda
   =20
   =20
    --__--__--
   =20
    Message: 2
    Date: Wed, 27 Nov 2002 16:22:34 +0100
    From: =3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D <toni@infurma.comb=
ios.es>
    To: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: [Pgsql-ayuda] =3D?iso-8859-1?Q?=3DBFC=3DF3mo_se_come_esto=3D3F=
?=3D
   =20
    (Consulta 1)
   =20
    habitat=3D# SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Cel=
da';
      id   |     marca
    -------+---------------
     21293 | Muebles Celda
   =20
   =20
    (Consulta 2)
   =20
    habitat=3D# SELECT id, marca FROM empresas WHERE id=3D21293;
     id | marca
    ----+-------
    (0 rows)
   =20
   =20
    (Estructura)
   =20
     id    | integer | not null default nextval('empresas_id_seq'::text)
     marca | character varying(128) |
   =20
   =20
    No entiendo porqu=E9 la segunda consulta no devuelve ninguna fila.
   =20
    =BFAlguna explicaci=F3n? =BFBase de datos corrupta?
   =20
    Gracias
   =20
    --=20
    Antonio M=E1rmol Albert ( toni@infurma.es )
    http://www.infurma.es
   =20
    --__--__--
   =20
    Message: 3
    From: "=3D?iso-8859-1?Q?Adri=3DE1n_Caldeiro?=3D" <caldeiro.uylug@adinet=
.com.uy>
    To: <pgsql-ayuda@tlali.iztacala.unam.mx>
    Date: Wed, 27 Nov 2002 12:27:00 -0300
    Subject: [Pgsql-ayuda] =3D?iso-8859-1?Q?RE:_=3D5BPgsql-ayuda=3D5D_=3DBF=
C=3DF3mo_se_come_esto=3D3F?=3D
   =20
    Proba con esto, es decir el id entre comillas simples.
   =20
    habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
   =20
    -----Mensaje original-----
    De: Antonio M=E1rmol Albert <toni@infurma.combios.es>
    Para: pgsql-ayuda@tlali.iztacala.unam.mx
    <pgsql-ayuda@tlali.iztacala.unam.mx>
    Fecha: Mi=E9rcoles 27 de Noviembre de 2002 12:19 PM
    Asunto: [Pgsql-ayuda] =BFC=F3mo se come esto?
   =20
   =20
    >(Consulta 1)
    >
    >habitat=3D# SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Ce=
lda';
    >  id   |     marca
    >-------+---------------
    > 21293 | Muebles Celda
    >
    >
    >(Consulta 2)
    >
    >habitat=3D# SELECT id, marca FROM empresas WHERE id=3D21293;
    > id | marca
    >----+-------
    >(0 rows)
    >
    >
    >(Estructura)
    >
    > id    | integer | not null default nextval('empresas_id_seq'::text)
    > marca | character varying(128) |
    >
    >
    >No entiendo porqu=E9 la segunda consulta no devuelve ninguna fila.
    >
    >=BFAlguna explicaci=F3n? =BFBase de datos corrupta?
    >
    >Gracias
    >
    >--
    >Antonio M=E1rmol Albert ( toni@infurma.es )
    >http://www.infurma.es
    >_______________________________________________
    >Pgsql-ayuda mailing list
    >Pgsql-ayuda@tlali.iztacala.unam.mx
    >http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda
   =20
   =20
    --__--__--
   =20
    Message: 4
    Subject: Re: [Pgsql-ayuda] Como veo todos los campos de una Base de dat=
os
    From: "Jaime N. Charles" =3D?ISO-8859-1?Q?Trevi=3DF1o?=3D <jcharles@cre=
dicoop.org.mx>
    To: Lista de Postgres <pgsql-ayuda@tlali.iztacala.unam.mx>
    Organization:=20
    Date: 27 Nov 2002 09:30:53 -0600
   =20
    El mar, 26-11-2002 a las 17:25, Edwin Alberto Quijada escribi=F3:
    > Hola a todos!!
    > Estoy tratando de hacer un programa que me imprima toda la estructura=
 de una=20
    > base de datos que esta en Postgres. Uso PgAdmin pero no encuentro por=
 ningun=20
    > lado una opcion que me permita hacerlo , por lo que he decidido hacer=
lo yo=20
    > mismo usando delphi. Mi pregunta es como yo puedo accesar las tablas =
y=20
    > campos de una tabla en Postgres, eso no se guarda en un catalogo o al=
go asi?
    > Si es asi diganme donde?
    > Gracias!!
    >=20
    Si lo que quieres es documentar puedes usar:=20
   =20
    PostgreSQL AutoDoc lo encuentras en:
   =20
    http://www.rbt.ca/autodoc/
   =20
    JCh
   =20
   =20
   =20
   =20
    --__--__--
   =20
    Message: 5
    Date: Wed, 27 Nov 2002 16:53:29 +0100
    From: =3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D <toni@infurma.comb=
ios.es>
    To: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: [Pgsql-ayuda] Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBF=
C=3DF3mo_se_come_esto=3D3F?=3D
   =20
    El mi=E9rcoles 27 de noviembre de 2002  (12:27), Adri=E1n Caldeiro escr=
ibi=F3:
   =20
    > Proba con esto, es decir el id entre comillas simples.
    >=20
    > habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
   =20
   =20
    habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
     id | marca
    ----+-------
    (0 rows)
   =20
   =20
    Lo mismo... =BFqu=E9 extra=F1o, no?
   =20
    --=20
    Antonio M=E1rmol Albert ( toni@infurma.es )
    http://www.infurma.es
   =20
    --__--__--
   =20
    Message: 6
    From: "=3D?iso-8859-1?q?V=3DEDctor=3D20R=3D2E?=3D Ruiz" <rvr@infoastro.=
com>
    To: Antonio =3D?iso-8859-1?q?M=3DE1rmol=3D20Albert?=3D <toni@infurma.co=
mbios.es>
    Subject: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =3D?iso-8859-1?q?=3DBFC=3D=
F3mo=3D20se=3D20come?=3D esto?
    Date: Wed, 27 Nov 2002 16:11:11 +0000
    Cc: pgsql-ayuda@tlali.iztacala.unam.mx
   =20
   =20
      Hola:
   =20
    El Mi=E9 27 Nov 2002 15:53, Antonio M=E1rmol Albert tecle=F3:
    > habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
    >  id | marca
    > ----+-------
    > (0 rows)
   =20
      Qu=E9 raro, s=ED. Mira a ver si te salen estos registros:
   =20
    SELECT id, marca FROM empresas WHERE id > '21290' AND < '21295';
   =20
      Saludetes,
   =20
    --=20
    V=EDctor R. Ruiz           | - Todos estos momentos se perder=E1n, como
    http://infoastro.com/rvr |   l=E1grimas en la lluvia.
   =20
   =20
    --__--__--
   =20
    Message: 7
    From: "J. Mario Oroz" <jmoroz@uol.com.ar>
    To: <pgsql-ayuda@tlali.iztacala.unam.mx>
    Date: Wed, 27 Nov 2002 13:21:24 -0300
    Subject: [Pgsql-ayuda] =3D?iso-8859-1?Q?Re:_=3D5BPgsql-ayuda=3D5D_Re:_=
=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_c?=3D
     =3D?iso-8859-1?Q?ome_esto=3D3F?=3D
   =20
    Hola a todos!
   =20
    Que version de Postgres tenes?
    Esto me suena a un bug en los indices de numeros enteros que observe po=
r la
    ver. 7.1.0 ... si mal no recuerdo...
    Mejor dicho un problema con la busqueda indexada, pues el explain me de=
cia
    que buscaba secuencialmente
    teniendo a mano un bruto indice para el parametro que pasaba al select.
    A lo mejor esta relacionado?!.
    Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.
    Se arregla con un cast del parametro a int8 o bigint.
    usa un explain a ver que dice!
   =20
    mario.
   =20
    ----- Original Message -----
    From: "Antonio M=E1rmol Albert" <toni@infurma.combios.es>
    To: <pgsql-ayuda@tlali.iztacala.unam.mx>
    Sent: Wednesday, November 27, 2002 12:53 PM
    Subject: [Pgsql-ayuda] Re: [Pgsql-ayuda] =BFC=F3mo se come esto?
   =20
   =20
    > El mi=E9rcoles 27 de noviembre de 2002  (12:27), Adri=E1n Caldeiro es=
cribi=F3:
    >
    > > Proba con esto, es decir el id entre comillas simples.
    > >
    > > habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
    >
    >
    > habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
    >  id | marca
    > ----+-------
    > (0 rows)
    >
    >
    > Lo mismo... =BFqu=E9 extra=F1o, no?
    >
    > --
    > Antonio M=E1rmol Albert ( toni@infurma.es )
    > http://www.infurma.es
    > _______________________________________________
    > Pgsql-ayuda mailing list
    > Pgsql-ayuda@tlali.iztacala.unam.mx
    > http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda
   =20
   =20
    --__--__--
   =20
    Message: 8
    Date: Wed, 27 Nov 2002 17:20:50 +0100
    From: =3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D <toni@infurma.comb=
ios.es>
    To: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: [Pgsql-ayuda] Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_Re:_=
=3D5BPgsql-ayuda=3D5D_=3DBFC=3DF3mo_se_come?=3D
     =3D?iso-8859-1?Q?_esto=3D3F?=3D
   =20
    El mi=E9rcoles 27 de noviembre de 2002  (16:11), V=EDctor R. Ruiz escri=
bi=F3:
   =20
    > El Mi=E9 27 Nov 2002 15:53, Antonio M=E1rmol Albert tecle=F3:
    > > habitat=3D# SELECT id, marca FROM empresas WHERE id=3D'21293';
    > >  id | marca
    > > ----+-------
    > > (0 rows)
    >=20
    >   Qu=E9 raro, s=ED. Mira a ver si te salen estos registros:
    >=20
    > SELECT id, marca FROM empresas WHERE id > '21290' AND < '21295';
   =20
    SELECT id, marca FROM empresas WHERE id > '21290' AND id < '21295';
      id   | marca
    -------+-------
     21291 | GOWAS
     21292 | GOWAS
     21294 |
    (3 rows)
   =20
    Pero...=20
   =20
    SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Celda';
      id   |     marca
    -------+---------------
     21293 | Muebles Celda
    (1 row)
   =20
    Al buscar por "id" no me sale ese registro. El campo "id" es la clave
    primaria de la tabla.
   =20
    Ya me di cuenta de esto otra vez (fue de casualidad, un error que vi en=
 una
    pagina de php) y no le di importancia. Hoy es la segunda vez que veo es=
to.
   =20
    No han habido cortes de luz ni cierres bruscos de la base de datos. Por=
 lo
    que no deberia estar corrupta.
   =20
    Sin embargo...
   =20
    SELECT id, marca FROM empresas WHERE id=3D'21292';
      id   | marca
    -------+-------
     21292 | GOWAS
    (1 row)
   =20
    Al parecer solo ocurre en X registros...
   =20
    =BFPuede ser un bug?
   =20
    --=20
    Antonio M=E1rmol Albert ( toni@infurma.es )
    http://www.infurma.es
   =20
    --__--__--
   =20
    Message: 9
    Date: Wed, 27 Nov 2002 17:23:13 +0100
    From: =3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D <toni@infurma.comb=
ios.es>
    To: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: [Pgsql-ayuda] Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBF=
C=3DF3mo_se_come_esto=3D3F?=3D
   =20
    El mi=E9rcoles 27 de noviembre de 2002  (13:21), J. Mario Oroz escribi=
=F3:
   =20
    > Hola a todos!
    >=20
    > Que version de Postgres tenes?
   =20
    rpm -q postgresql
   =20
    postgresql-7.2-1
   =20
    > Esto me suena a un bug en los indices de numeros enteros que observe =
por la
    > ver. 7.1.0 ... si mal no recuerdo...
    > Mejor dicho un problema con la busqueda indexada, pues el explain me =
decia
    > que buscaba secuencialmente
    > teniendo a mano un bruto indice para el parametro que pasaba al selec=
t.
    > A lo mejor esta relacionado?!.
    > Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.
    > Se arregla con un cast del parametro a int8 o bigint.
    > usa un explain a ver que dice!
   =20
    Esto =FAltimo no lo entiendo / no se como se hace. :)
   =20
    --=20
    Antonio M=E1rmol Albert ( toni@infurma.es )
    http://www.infurma.es
   =20
    --__--__--
   =20
    Message: 10
    From: "=3D?iso-8859-1?q?V=3DEDctor=3D20R=3D2E?=3D Ruiz" <rvr@infoastro.=
com>
    To: Antonio =3D?iso-8859-1?q?M=3DE1rmol=3D20Albert?=3D <toni@infurma.co=
mbios.es>
    Subject: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =3D?iso-=
8859-1?q?=3DBFC=3DF3mo=3D20se=3D20come?=3D esto?
    Date: Wed, 27 Nov 2002 16:49:49 +0000
    Cc: pgsql-ayuda@tlali.iztacala.unam.mx
   =20
   =20
      Hola:
   =20
    El Mi=E9 27 Nov 2002 16:20, Antonio M=E1rmol Albert tecle=F3:
    > =BFPuede ser un bug?
   =20
      =A1Tiene pinta de serlo! Me acabas de acongojar :) Pregunta en las=20
    listas de PostgreSQL: http://www.ca.postgresql.org/users-lounge/
   =20
      Saludetes,
   =20
    --=20
    V=EDctor R. Ruiz           | - Todos estos momentos se perder=E1n, como
    http://infoastro.com/rvr |   l=E1grimas en la lluvia.
   =20
   =20
    --__--__--
   =20
    Message: 11
    From: Cesar Villanueva <dandel@etheron.net>
    To: Antonio =3D?iso-8859-1?q?M=3DE1rmol=3D20Albert?=3D <toni@infurma.co=
mbios.es>,
    	pgsql-ayuda@tlali.iztacala.unam.mx
    Date: Wed, 27 Nov 2002 13:11:48 -0400
    Subject: [Pgsql-ayuda] =3D?iso-8859-1?q?=3DBFC=3DF3mo=3D20se=3D20come?=
=3D esto?
   =20
    Hola *
   =20
    A m=ED lo que me parece es que el id de 'Muebles Celda' _no_ es=20
    '21293'; quiz=E1 es '21293 ' o bien ' 21293'. Es decir, que hay un espa=
cio (u=20
    otro caracter invisible antes o despu=E9s del n=FAmero en s=ED.=20
   =20
    Algo como=20
   =20
    SELECT id, marca FROM empresas WHERE id LIKE '%2129%';
   =20
    y producir algio como:
   =20
       id   | marca
     -------+-------
    (...)
      21291 | GOWAS
      21292 | GOWAS
      21293 | Muebles Celda
      21294 |
    (..)
   =20
   =20
    Si es as=ED entonces el problema est=E1 en la rutina que ingresa el n=
=FAmero de id=20
    (es raro si es una secuencia o SERIAL) pero si es introducida por el us=
uario=20
    estonces debes validar que no se ingresen caracteres extra=F1os...
   =20
    =BFC=F3mo _corregir_  el registro?=20
   =20
    Prueba hacer un UPDATE de la siguiente forma:
   =20
    UPDATE empresas set id=3D'21293' where marca =3D'Muebles Celda';
   =20
    (por tu llamada anterior estamos seguros que hay una sola instancia de=20
    "Muebles Celda"; caso contrario debes usar el oid.
   =20
    SELECT oid, marca FROM empresas WHERE marca =3D 'Muebles Celda';
      oid   |     marca
    -------+---------------
    55555 | Muebles Celda
   =20
    y actualizas
   =20
    UPDATE empresas set id=3D'21293' where oid =3D'55555';
   =20
   =20
    El Mi=E9rcoles 27 Noviembre 2002 12:20, Antonio M=E1rmol Albert escribi=
=F3:
    > SELECT id, marca FROM empresas WHERE id > '21290' AND id < '21295';
    >   id   | marca
    > -------+-------
    >  21291 | GOWAS
    >  21292 | GOWAS
    >  21294 |
    > (3 rows)
    >
    > Pero...
    >
    > SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Celda';
    >   id   |     marca
    > -------+---------------
    >  21293 | Muebles Celda
    > (1 row)
    >
    > Al buscar por "id" no me sale ese registro. El campo "id" es la clave
    > primaria de la tabla.
    >
    > Ya me di cuenta de esto otra vez (fue de casualidad, un error que vi =
en una
    > pagina de php) y no le di importancia. Hoy es la segunda vez que veo =
esto.
    >
    > No han habido cortes de luz ni cierres bruscos de la base de datos. P=
or lo
    > que no deberia estar corrupta.
    >
    > Sin embargo...
    >
    > SELECT id, marca FROM empresas WHERE id=3D'21292';
    >   id   | marca
    > -------+-------
    >  21292 | GOWAS
    > (1 row)
    >
    > Al parecer solo ocurre en X registros...
    >
    > =BFPuede ser un bug?
   =20
    --=20
    C=E9sar Villanueva
    Operations Manager
    SuSE Linux C.A.
    Cel. 0416-6153429
   =20
    --__--__--
   =20
    Message: 12
    From: "J. Mario Oroz" <jmoroz@uol.com.ar>
    To: <pgsql-ayuda@tlali.iztacala.unam.mx>
    Date: Wed, 27 Nov 2002 14:38:10 -0300
    Subject: [Pgsql-ayuda] =3D?iso-8859-1?Q?Re:_=3D5BPgsql-ayuda=3D5D_=3DBF=
C=3DF3mo_se_come_esto=3D3F?=3D
   =20
   =20
    ----- Original Message -----
    From: "Antonio M=E1rmol Albert" <toni@infurma.combios.es>
    To: <pgsql-ayuda@tlali.iztacala.unam.mx>
    Sent: Wednesday, November 27, 2002 1:23 PM
    Subject: [Pgsql-ayuda] Re: [Pgsql-ayuda] =BFC=F3mo se come esto?
   =20
   =20
    > El mi=E9rcoles 27 de noviembre de 2002  (13:21), J. Mario Oroz escrib=
i=F3:
    >
    > > Hola a todos!
    > >
    > > Que version de Postgres tenes?
    >
    > rpm -q postgresql
    >
    > postgresql-7.2-1
    >
    > > Esto me suena a un bug en los indices de numeros enteros que observ=
e por
    la
    > > ver. 7.1.0 ... si mal no recuerdo...
    > > Mejor dicho un problema con la busqueda indexada, pues el explain m=
e
    decia
    > > que buscaba secuencialmente
    > > teniendo a mano un bruto indice para el parametro que pasaba al sel=
ect.
    > > A lo mejor esta relacionado?!.
    > > Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.
    > > Se arregla con un cast del parametro a int8 o bigint.
    > > usa un explain a ver que dice!
    >
    > Esto =FAltimo no lo entiendo / no se como se hace. :)
   =20
    Seria algo comoesto:
   =20
    EXPLAIN SELECT id, marca FROM empresas WHERE id=3D21293::bigint;
   =20
    =F3
   =20
    EXPLAIN SELECT id, marca FROM empresas WHERE id=3D'21293'::bigint;
   =20
    Mira ... este es un extracto del mail que postie en aquel momento...
   =20
    ...
    Luego ejecute VACUUM ANALIZE y luego un select de la forma:
   =20
    EXPLAIN SELECT * FROM clientes WHERE tipo_doc=3D1::smallint AND
    nro_doc=3D23356::bigint;
   =20
    El resultado fue un bonito "Index Scan on tn_cli_idx" ... es decir us=
=F3 el
    vendito indice.
    ...
   =20
    Nota: Hiciste un VACUUM ANALIZE?
   =20
    Aunque me parece que va por otro lado!, puesto que si funciona el selec=
t con
    otros id's.
   =20
   =20
    Mario.
   =20
   =20
    --__--__--
   =20
    Message: 13
    To: Antonio =3D?iso-8859-1?q?M=3DE1rmol?=3D Albert <toni@infurma.combio=
s.es>
    Cc: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: Re: [Pgsql-ayuda] =3D?iso-8859-1?q?=3DBFC=3DF3mo?=3D se come e=
sto?
    From: Manuel Sugawara <masm@fciencias.unam.mx>
    Date: 27 Nov 2002 11:49:21 -0600
   =20
    Antonio M=3DE1rmol Albert <toni@infurma.combios.es> writes:
   =20
    > (Consulta 1)
    >=3D20
    > habitat=3D3D# SELECT id, marca FROM empresas WHERE marca =3D3D 'Muebl=
es Celda=3D
    ';
    >   id   |     marca
    > -------+---------------
    >  21293 | Muebles Celda
    >=3D20
    >=3D20
    > (Consulta 2)
    >=3D20
    > habitat=3D3D# SELECT id, marca FROM empresas WHERE id=3D3D21293;
    >  id | marca
    > ----+-------
    > (0 rows)
   =20
    umh, esta raro. Tal vez tienes un =3DEDndice corrupto; =3DBFdices que i=
d es
    llave primaria?, tal vez algo como:
   =20
      reindex empresas_pkey;
   =20
    ayude. =3DBFqu=3DE9 te dice el explain de abajo?
   =20
      explain analyze SELECT id, marca FROM empresas WHERE id=3D3D21293;
   =20
    Saludos,
    Manuel.
   =20
    --__--__--
   =20
    Message: 14
    Date: Wed, 27 Nov 2002 18:42:56 +0100
    From: =3D?iso-8859-1?Q?Antonio_M=3DE1rmol_Albert?=3D <toni@infurma.comb=
ios.es>
    To: pgsql-ayuda@tlali.iztacala.unam.mx
    Subject: [Pgsql-ayuda] Re: =3D?iso-8859-1?Q?=3D5BPgsql-ayuda=3D5D_=3DBF=
C=3DF3mo_se_come_esto=3D3F?=3D
   =20
    El mi=E9rcoles 27 de noviembre de 2002  (13:11), Cesar Villanueva escri=
bi=F3:
   =20
    > Hola *
    >=20
    > A m=ED lo que me parece es que el id de 'Muebles Celda' _no_ es=20
    > '21293'; quiz=E1 es '21293 ' o bien ' 21293'. Es decir, que hay un es=
pacio (u=20
    > otro caracter invisible antes o despu=E9s del n=FAmero en s=ED.=20
    >=20
    > Algo como=20
    >=20
    > SELECT id, marca FROM empresas WHERE id LIKE '%2129%';
    >=20
    > y producir algio como:
    >=20
    >    id   | marca
    >  -------+-------
    > (...)
    >   21291 | GOWAS
    >   21292 | GOWAS
    >   21293 | Muebles Celda
    >   21294 |
    > (..)
   =20
    habitat=3D# SELECT id, marca FROM empresas WHERE id LIKE '%2129%';
      id   |     marca
    -------+----------------
      2129 |
     12129 |
     21293 | Muebles Celda
     21295 |
     21294 |
     21297 | mueble moderno
     21298 |
     22129 |
     21291 | GOWAS
     21292 | GOWAS
     21299 | CONSTRUCTIVA
    (11 rows)
   =20
   =20
    As=ED, S=CD que sale. =BFPor qu=E9 as=ED s=ED? No lo entiendo... id es =
un campo entero
    (tipo SERIAL). Puedo arreglar ese registro, pero... =BFcu=E1ntos regist=
ros
    tendr=E9 igual que es? Puede ser un problema. :/
   =20
    El n=FAmero de id se obtiene de una secuencia. En ning=FAn momento se i=
ntroduce
    manualmente.
   =20
    Gracias a todos por la atenci=F3n prestada.
   =20
    Y ahora otra... =BFc=F3mo prevenir eso? :)
   =20
    > Si es as=ED entonces el problema est=E1 en la rutina que ingresa el n=
=FAmero de id=20
    > (es raro si es una secuencia o SERIAL) pero si es introducida por el =
usuario=20
    > estonces debes validar que no se ingresen caracteres extra=F1os...
    >=20
    > =BFC=F3mo _corregir_  el registro?=20
    >=20
    > Prueba hacer un UPDATE de la siguiente forma:
    >=20
    > UPDATE empresas set id=3D'21293' where marca =3D'Muebles Celda';
    >=20
    > (por tu llamada anterior estamos seguros que hay una sola instancia d=
e=20
    > "Muebles Celda"; caso contrario debes usar el oid.
    >=20
    > SELECT oid, marca FROM empresas WHERE marca =3D 'Muebles Celda';
    >   oid   |     marca
    > -------+---------------
    > 55555 | Muebles Celda
    >=20
    > y actualizas
    >=20
    > UPDATE empresas set id=3D'21293' where oid =3D'55555';
    >=20
    >=20
    > El Mi=E9rcoles 27 Noviembre 2002 12:20, Antonio M=E1rmol Albert escri=
bi=F3:
    > > SELECT id, marca FROM empresas WHERE id > '21290' AND id < '21295';
    > >   id   | marca
    > > -------+-------
    > >  21291 | GOWAS
    > >  21292 | GOWAS
    > >  21294 |
    > > (3 rows)
    > >
    > > Pero...
    > >
    > > SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Celda';
    > >   id   |     marca
    > > -------+---------------
    > >  21293 | Muebles Celda
    > > (1 row)
    > >
    > > Al buscar por "id" no me sale ese registro. El campo "id" es la cla=
ve
    > > primaria de la tabla.
    > >
    > > Ya me di cuenta de esto otra vez (fue de casualidad, un error que v=
i en una
    > > pagina de php) y no le di importancia. Hoy es la segunda vez que ve=
o esto.
    > >
    > > No han habido cortes de luz ni cierres bruscos de la base de datos.=
 Por lo
    > > que no deberia estar corrupta.
    > >
    > > Sin embargo...
    > >
    > > SELECT id, marca FROM empresas WHERE id=3D'21292';
    > >   id   | marca
    > > -------+-------
    > >  21292 | GOWAS
    > > (1 row)
    > >
    > > Al parecer solo ocurre en X registros...
    > >
    > > =BFPuede ser un bug?
   =20
    --=20
    Antonio M=E1rmol Albert ( toni@infurma.es )
    http://www.infurma.es
   =20
   =20
    --__--__--
   =20
    _______________________________________________
    Pgsql-ayuda mailing list
    Pgsql-ayuda@tlali.iztacala.unam.mx
    http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda
   =20
   =20
    End of Pgsql-ayuda Digest
   =20

--=-iwlh3UXSAevths4Z/w+p
Content-Type: text/html; charset=utf-8

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
  <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
  <META NAME="GENERATOR" CONTENT="GtkHTML/1.0.4.99">
</HEAD>
<BODY>
SALUDOS.
<BR>

<BR>
NECESITO SI ALGUIEN ME PUEDE ORIENTAR COMO CORREGIR EL SIGUIENTE ERROR QUE ME APARECE EN POSTGRES.
<BR>

<BR>

<BR>
java.sql.SQLException: IOError while reading from backend: java.io.IOException
<BR>

<BR>
REGULARMENTE ME APARECE EL MENSAJE &quot; intente la operacion m&#225;s tarde &quot;, LO QUE HAGO ES REINICIAR, PERO ES UN ERROR QUE ES CONSTANTE
<BR>

<BR>
LA VERSION QUE TENGO DE POSTGRES ES : el 6..5 
<BR>

<BR>
De antemano muchas gracias.
<BR>

<BR>
Attn.
<BR>
---
<BR>
Ricardo Col&#237;n
<BR>

<BR>

<BR>

<BR>
El mi&#233;, 27-11-2002 a las 11:48, pgsql-ayuda-request@tlali.iztacala.unam.mx escribi&#243;:
    <BLOCKQUOTE>
<PRE><FONT COLOR="#474073"><FONT SIZE="3"><I>Send Pgsql-ayuda mailing list submissions to</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>	pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To subscribe or unsubscribe via the World Wide Web, visit</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>	http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>or, via email, send a message with subject or body 'help' to</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>	pgsql-ayuda-request@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>You can reach the person managing the list at</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>	pgsql-ayuda-admin@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>When replying, please edit your Subject line so it is more specific</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>than &quot;Re: Contents of Pgsql-ayuda digest...&quot;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Today's Topics:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   1. Re: Uso de postgres desde PHP (Edgar Raul Acosta =?iso-8859-1?q?Villase=F1or?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   2. =?iso-8859-1?Q?=BFC=F3mo_se_come_esto=3F?= (=?iso-8859-1?Q?Antonio_M=E1rmol_Albert?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   3. =?iso-8859-1?Q?RE:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?= (=?iso-8859-1?Q?Adri=E1n_Caldeiro?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   4. Re: Como veo todos los campos de una Base de datos (Jaime N. Charles =?ISO-8859-1?Q?Trevi=F1o?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   5. Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?= (=?iso-8859-1?Q?Antonio_M=E1rmol_Albert?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   6. Re: Re: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto? (=?iso-8859-1?q?V=EDctor=20R=2E?= Ruiz)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   7. =?iso-8859-1?Q?Re:_=5BPgsql-ayuda=5D_Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_c?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>       =?iso-8859-1?Q?ome_esto=3F?= (J. Mario Oroz)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   8. Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>       =?iso-8859-1?Q?_esto=3F?= (=?iso-8859-1?Q?Antonio_M=E1rmol_Albert?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   9. Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?= (=?iso-8859-1?Q?Antonio_M=E1rmol_Albert?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  10. Re: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto? (=?iso-8859-1?q?V=EDctor=20R=2E?= Ruiz)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  11. =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto? (Cesar Villanueva)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  12. =?iso-8859-1?Q?Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?= (J. Mario Oroz)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  13. Re: =?iso-8859-1?q?=BFC=F3mo?= se come esto? (Manuel Sugawara)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  14. Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?= (=?iso-8859-1?Q?Antonio_M=E1rmol_Albert?=)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 1</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: Edgar Raul Acosta =?iso-8859-1?q?Villase=F1or?= &lt;edgar@tlahui.posgrado.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: Re: [Pgsql-ayuda] Uso de postgres desde PHP</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 08:55:55 -0600</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Hola,</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>=09Por los datos que proporcionas, me parece que tienes que revisar(modif=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>icar)=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>el archivo data/pg_hba en el directorio de trabajo de postgresql. En ese=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>archivo est=E1n los permisos de acceso a la base de datos, as=ED que esa=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>configuraci=F3n debe corresponder a la seguridad que desees, el mismo arc=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>hivo=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>te explica c=F3mo modificarlo.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>=09Adem=E1s tienes que estar seguro que el servicio de postgres acepta co=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>nexiones=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>por red y en el puerto 5432.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>=09Saludos</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>=09=09Edgar Acosta</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El Mi=E9 27 Nov 2002 06:30, Adri=E1n Caldeiro escribi=F3:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Hola a todos.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;     Estoy empezando con postgres, lo instale en Debian Woody, lei la</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; documentacion e incluso busque informaci=F3n en Internet, pero no encue=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>nto</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; como solucionar el tema de como acceder a postgres desde PHP.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;      El tema es que desde la linea de comando, puedo acceder, crear bas=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; de datos, insertar, etc ..., pero, si lo intento hacer desde PHP me da</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; varios errores, si no le pongo usuario me dice &quot;www-data no existe en e=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>sta</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; pagina&quot;, si le pongo como usurario postgres &quot;me dice que no lo puede</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; validar&quot; (el usuario postgres no tiene password), si le coloco un passw=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>ord</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; y lo quiero usar con dicho password tambien me da problemas.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;     Alguno tiene idea cual puede ser la soluci=F3n, desde ya muchas gra=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>cias.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Saludos Adri=E1n.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; _______________________________________________</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Pgsql-ayuda mailing list</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 2</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 16:22:34 +0100</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: =?iso-8859-1?Q?Antonio_M=E1rmol_Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] =?iso-8859-1?Q?=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(Consulta 1)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>habitat=# SELECT id, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(Consulta 2)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>habitat=# SELECT id, marca FROM empresas WHERE id=21293;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(Estructura)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> id    | integer | not null default nextval('empresas_id_seq'::text)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> marca | character varying(128) |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>No entiendo porqu&#233; la segunda consulta no devuelve ninguna fila.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&#191;Alguna explicaci&#243;n? &#191;Base de datos corrupta?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Gracias</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 3</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;=?iso-8859-1?Q?Adri=E1n_Caldeiro?=&quot; &lt;caldeiro.uylug@adinet.com.uy&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 12:27:00 -0300</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] =?iso-8859-1?Q?RE:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Proba con esto, es decir el id entre comillas simples.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-----Mensaje original-----</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>De: Antonio M&#225;rmol Albert &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Para: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Fecha: Mi&#233;rcoles 27 de Noviembre de 2002 12:19 PM</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Asunto: [Pgsql-ayuda] &#191;C&#243;mo se come esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;(Consulta 1)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;habitat=# SELECT id, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;-------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; 21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;(Consulta 2)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;habitat=# SELECT id, marca FROM empresas WHERE id=21293;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;(0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;(Estructura)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; id    | integer | not null default nextval('empresas_id_seq'::text)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; marca | character varying(128) |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;No entiendo porqu&#233; la segunda consulta no devuelve ninguna fila.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;&#191;Alguna explicaci&#243;n? &#191;Base de datos corrupta?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;Gracias</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;_______________________________________________</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;Pgsql-ayuda mailing list</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;Pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 4</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: Re: [Pgsql-ayuda] Como veo todos los campos de una Base de datos</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;Jaime N. Charles&quot; =?ISO-8859-1?Q?Trevi=F1o?= &lt;jcharles@credicoop.org.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Lista de Postgres &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Organization: </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: 27 Nov 2002 09:30:53 -0600</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El mar, 26-11-2002 a las 17:25, Edwin Alberto Quijada escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Hola a todos!!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Estoy tratando de hacer un programa que me imprima toda la estructura de una </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; base de datos que esta en Postgres. Uso PgAdmin pero no encuentro por ningun </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; lado una opcion que me permita hacerlo , por lo que he decidido hacerlo yo </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; mismo usando delphi. Mi pregunta es como yo puedo accesar las tablas y </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; campos de una tabla en Postgres, eso no se guarda en un catalogo o algo asi?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Si es asi diganme donde?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Gracias!!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Si lo que quieres es documentar puedes usar: </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>PostgreSQL AutoDoc lo encuentras en:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.rbt.ca/autodoc/</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>JCh</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 5</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 16:53:29 +0100</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: =?iso-8859-1?Q?Antonio_M=E1rmol_Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El mi&#233;rcoles 27 de noviembre de 2002  (12:27), Adri&#225;n Caldeiro escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Proba con esto, es decir el id entre comillas simples.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Lo mismo... &#191;qu&#233; extra&#241;o, no?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 6</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;=?iso-8859-1?q?V=EDctor=20R=2E?= Ruiz&quot; &lt;rvr@infoastro.com&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Antonio =?iso-8859-1?q?M=E1rmol=20Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 16:11:11 +0000</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Cc: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  Hola:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El Mi&#233; 27 Nov 2002 15:53, Antonio M&#225;rmol Albert tecle&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; ----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  Qu&#233; raro, s&#237;. Mira a ver si te salen estos registros:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT id, marca FROM empresas WHERE id &gt; '21290' AND &lt; '21295';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  Saludetes,</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>V&#237;ctor R. Ruiz           | - Todos estos momentos se perder&#225;n, como</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://infoastro.com/rvr |   l&#225;grimas en la lluvia.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 7</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;J. Mario Oroz&quot; &lt;jmoroz@uol.com.ar&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 13:21:24 -0300</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] =?iso-8859-1?Q?Re:_=5BPgsql-ayuda=5D_Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_c?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> =?iso-8859-1?Q?ome_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Hola a todos!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Que version de Postgres tenes?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Esto me suena a un bug en los indices de numeros enteros que observe por la</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>ver. 7.1.0 ... si mal no recuerdo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Mejor dicho un problema con la busqueda indexada, pues el explain me decia</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>que buscaba secuencialmente</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>teniendo a mano un bruto indice para el parametro que pasaba al select.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>A lo mejor esta relacionado?!.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Se arregla con un cast del parametro a int8 o bigint.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>usa un explain a ver que dice!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>mario.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>----- Original Message -----</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;Antonio M&#225;rmol Albert&quot; &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Sent: Wednesday, November 27, 2002 12:53 PM</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: [Pgsql-ayuda] &#191;C&#243;mo se come esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; El mi&#233;rcoles 27 de noviembre de 2002  (12:27), Adri&#225;n Caldeiro escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Proba con esto, es decir el id entre comillas simples.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; ----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Lo mismo... &#191;qu&#233; extra&#241;o, no?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; --</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; _______________________________________________</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Pgsql-ayuda mailing list</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 8</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 17:20:50 +0100</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: =?iso-8859-1?Q?Antonio_M=E1rmol_Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> =?iso-8859-1?Q?_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El mi&#233;rcoles 27 de noviembre de 2002  (16:11), V&#237;ctor R. Ruiz escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; El Mi&#233; 27 Nov 2002 15:53, Antonio M&#225;rmol Albert tecle&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; habitat=# SELECT id, marca FROM empresas WHERE id='21293';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; ----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; (0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   Qu&#233; raro, s&#237;. Mira a ver si te salen estos registros:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT id, marca FROM empresas WHERE id &gt; '21290' AND &lt; '21295';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT id, marca FROM empresas WHERE id &gt; '21290' AND id &lt; '21295';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(3 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Pero... </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT id, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Al buscar por &quot;id&quot; no me sale ese registro. El campo &quot;id&quot; es la clave</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>primaria de la tabla.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Ya me di cuenta de esto otra vez (fue de casualidad, un error que vi en una</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>pagina de php) y no le di importancia. Hoy es la segunda vez que veo esto.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>No han habido cortes de luz ni cierres bruscos de la base de datos. Por lo</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>que no deberia estar corrupta.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Sin embargo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT id, marca FROM empresas WHERE id='21292';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Al parecer solo ocurre en X registros...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&#191;Puede ser un bug?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 9</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 17:23:13 +0100</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: =?iso-8859-1?Q?Antonio_M=E1rmol_Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El mi&#233;rcoles 27 de noviembre de 2002  (13:21), J. Mario Oroz escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Hola a todos!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Que version de Postgres tenes?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>rpm -q postgresql</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>postgresql-7.2-1</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Esto me suena a un bug en los indices de numeros enteros que observe por la</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; ver. 7.1.0 ... si mal no recuerdo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Mejor dicho un problema con la busqueda indexada, pues el explain me decia</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; que buscaba secuencialmente</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; teniendo a mano un bruto indice para el parametro que pasaba al select.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; A lo mejor esta relacionado?!.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Se arregla con un cast del parametro a int8 o bigint.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; usa un explain a ver que dice!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Esto &#250;ltimo no lo entiendo / no se como se hace. :)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 10</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;=?iso-8859-1?q?V=EDctor=20R=2E?= Ruiz&quot; &lt;rvr@infoastro.com&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Antonio =?iso-8859-1?q?M=E1rmol=20Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] Re: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 16:49:49 +0000</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Cc: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  Hola:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El Mi&#233; 27 Nov 2002 16:20, Antonio M&#225;rmol Albert tecle&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &#191;Puede ser un bug?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  &#161;Tiene pinta de serlo! Me acabas de acongojar :) Pregunta en las </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>listas de PostgreSQL: http://www.ca.postgresql.org/users-lounge/</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  Saludetes,</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>V&#237;ctor R. Ruiz           | - Todos estos momentos se perder&#225;n, como</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://infoastro.com/rvr |   l&#225;grimas en la lluvia.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 11</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: Cesar Villanueva &lt;dandel@etheron.net&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Antonio =?iso-8859-1?q?M=E1rmol=20Albert?= &lt;toni@infurma.combios.es&gt;,</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>	pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 13:11:48 -0400</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo=20se=20come?= esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Hola *</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>A m&#237; lo que me parece es que el id de 'Muebles Celda' _no_ es </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>'21293'; quiz&#225; es '21293 ' o bien ' 21293'. Es decir, que hay un espacio (u </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>otro caracter invisible antes o despu&#233;s del n&#250;mero en s&#237;. </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Algo como </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT id, marca FROM empresas WHERE id LIKE '%2129%';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>y producir algio como:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>   id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(...)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(..)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Si es as&#237; entonces el problema est&#225; en la rutina que ingresa el n&#250;mero de id </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(es raro si es una secuencia o SERIAL) pero si es introducida por el usuario </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>estonces debes validar que no se ingresen caracteres extra&#241;os...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&#191;C&#243;mo _corregir_  el registro? </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Prueba hacer un UPDATE de la siguiente forma:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>UPDATE empresas set id='21293' where marca ='Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(por tu llamada anterior estamos seguros que hay una sola instancia de </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&quot;Muebles Celda&quot;; caso contrario debes usar el oid.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SELECT oid, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  oid   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>55555 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>y actualizas</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>UPDATE empresas set id='21293' where oid ='55555';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El Mi&#233;rcoles 27 Noviembre 2002 12:20, Antonio M&#225;rmol Albert escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT id, marca FROM empresas WHERE id &gt; '21290' AND id &lt; '21295';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (3 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Pero...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT id, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; -------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Al buscar por &quot;id&quot; no me sale ese registro. El campo &quot;id&quot; es la clave</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; primaria de la tabla.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Ya me di cuenta de esto otra vez (fue de casualidad, un error que vi en una</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; pagina de php) y no le di importancia. Hoy es la segunda vez que veo esto.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; No han habido cortes de luz ni cierres bruscos de la base de datos. Por lo</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; que no deberia estar corrupta.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Sin embargo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT id, marca FROM empresas WHERE id='21292';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Al parecer solo ocurre en X registros...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &#191;Puede ser un bug?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>C&#233;sar Villanueva</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Operations Manager</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>SuSE Linux C.A.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Cel. 0416-6153429</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 12</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;J. Mario Oroz&quot; &lt;jmoroz@uol.com.ar&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 14:38:10 -0300</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] =?iso-8859-1?Q?Re:_=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>----- Original Message -----</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: &quot;Antonio M&#225;rmol Albert&quot; &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: &lt;pgsql-ayuda@tlali.iztacala.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Sent: Wednesday, November 27, 2002 1:23 PM</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: [Pgsql-ayuda] &#191;C&#243;mo se come esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; El mi&#233;rcoles 27 de noviembre de 2002  (13:21), J. Mario Oroz escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Hola a todos!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Que version de Postgres tenes?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; rpm -q postgresql</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; postgresql-7.2-1</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Esto me suena a un bug en los indices de numeros enteros que observe por</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>la</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; ver. 7.1.0 ... si mal no recuerdo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Mejor dicho un problema con la busqueda indexada, pues el explain me</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>decia</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; que buscaba secuencialmente</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; teniendo a mano un bruto indice para el parametro que pasaba al select.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; A lo mejor esta relacionado?!.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Algo postie a la lista y me lo confirmo el Ing.Andrade Fonseca.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Se arregla con un cast del parametro a int8 o bigint.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; usa un explain a ver que dice!</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Esto &#250;ltimo no lo entiendo / no se como se hace. :)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Seria algo comoesto:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>EXPLAIN SELECT id, marca FROM empresas WHERE id=21293::bigint;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&#243;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>EXPLAIN SELECT id, marca FROM empresas WHERE id='21293'::bigint;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Mira ... este es un extracto del mail que postie en aquel momento...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Luego ejecute VACUUM ANALIZE y luego un select de la forma:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>EXPLAIN SELECT * FROM clientes WHERE tipo_doc=1::smallint AND</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>nro_doc=23356::bigint;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El resultado fue un bonito &quot;Index Scan on tn_cli_idx&quot; ... es decir us&#243; el</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>vendito indice.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Nota: Hiciste un VACUUM ANALIZE?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Aunque me parece que va por otro lado!, puesto que si funciona el select con</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>otros id's.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Mario.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 13</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: Antonio =?iso-8859-1?q?M=E1rmol?= Albert &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Cc: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: Re: [Pgsql-ayuda] =?iso-8859-1?q?=BFC=F3mo?= se come esto?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: Manuel Sugawara &lt;masm@fciencias.unam.mx&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: 27 Nov 2002 11:49:21 -0600</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M=E1rmol Albert &lt;toni@infurma.combios.es&gt; writes:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (Consulta 1)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; habitat=3D# SELECT id, marca FROM empresas WHERE marca =3D 'Muebles Celda=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; -------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (Consulta 2)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;=20</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; habitat=3D# SELECT id, marca FROM empresas WHERE id=3D21293;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  id | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; ----+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (0 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>umh, esta raro. Tal vez tienes un =EDndice corrupto; =BFdices que id es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>llave primaria?, tal vez algo como:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  reindex empresas_pkey;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>ayude. =BFqu=E9 te dice el explain de abajo?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  explain analyze SELECT id, marca FROM empresas WHERE id=3D21293;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Saludos,</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Manuel.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Message: 14</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Date: Wed, 27 Nov 2002 18:42:56 +0100</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>From: =?iso-8859-1?Q?Antonio_M=E1rmol_Albert?= &lt;toni@infurma.combios.es&gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>To: pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Subject: [Pgsql-ayuda] Re: =?iso-8859-1?Q?=5BPgsql-ayuda=5D_=BFC=F3mo_se_come_esto=3F?=</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El mi&#233;rcoles 27 de noviembre de 2002  (13:11), Cesar Villanueva escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Hola *</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; A m&#237; lo que me parece es que el id de 'Muebles Celda' _no_ es </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; '21293'; quiz&#225; es '21293 ' o bien ' 21293'. Es decir, que hay un espacio (u </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; otro caracter invisible antes o despu&#233;s del n&#250;mero en s&#237;. </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Algo como </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT id, marca FROM empresas WHERE id LIKE '%2129%';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; y producir algio como:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;    id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;  -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (...)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (..)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>habitat=# SELECT id, marca FROM empresas WHERE id LIKE '%2129%';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-------+----------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>  2129 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 12129 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21295 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21297 | mueble moderno</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21298 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 22129 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I> 21299 | CONSTRUCTIVA</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(11 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>As&#237;, S&#205; que sale. &#191;Por qu&#233; as&#237; s&#237;? No lo entiendo... id es un campo entero</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>(tipo SERIAL). Puedo arreglar ese registro, pero... &#191;cu&#225;ntos registros</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>tendr&#233; igual que es? Puede ser un problema. :/</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>El n&#250;mero de id se obtiene de una secuencia. En ning&#250;n momento se introduce</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>manualmente.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Gracias a todos por la atenci&#243;n prestada.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Y ahora otra... &#191;c&#243;mo prevenir eso? :)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Si es as&#237; entonces el problema est&#225; en la rutina que ingresa el n&#250;mero de id </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (es raro si es una secuencia o SERIAL) pero si es introducida por el usuario </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; estonces debes validar que no se ingresen caracteres extra&#241;os...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &#191;C&#243;mo _corregir_  el registro? </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; Prueba hacer un UPDATE de la siguiente forma:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; UPDATE empresas set id='21293' where marca ='Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; (por tu llamada anterior estamos seguros que hay una sola instancia de </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &quot;Muebles Celda&quot;; caso contrario debes usar el oid.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; SELECT oid, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt;   oid   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; -------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; 55555 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; y actualizas</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; UPDATE empresas set id='21293' where oid ='55555';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; El Mi&#233;rcoles 27 Noviembre 2002 12:20, Antonio M&#225;rmol Albert escribi&#243;:</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; SELECT id, marca FROM empresas WHERE id &gt; '21290' AND id &lt; '21295';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;   id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  21291 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  21294 |</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; (3 rows)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Pero...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; SELECT id, marca FROM empresas WHERE marca = 'Muebles Celda';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;   id   |     marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; -------+---------------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  21293 | Muebles Celda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; (1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Al buscar por &quot;id&quot; no me sale ese registro. El campo &quot;id&quot; es la clave</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; primaria de la tabla.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Ya me di cuenta de esto otra vez (fue de casualidad, un error que vi en una</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; pagina de php) y no le di importancia. Hoy es la segunda vez que veo esto.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; No han habido cortes de luz ni cierres bruscos de la base de datos. Por lo</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; que no deberia estar corrupta.</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Sin embargo...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; SELECT id, marca FROM empresas WHERE id='21292';</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;   id   | marca</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; -------+-------</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;  21292 | GOWAS</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; (1 row)</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; Al parecer solo ocurre en X registros...</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt;</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>&gt; &gt; &#191;Puede ser un bug?</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>-- </FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Antonio M&#225;rmol Albert ( toni@infurma.es )</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://www.infurma.es</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>--__--__--</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>_______________________________________________</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Pgsql-ayuda mailing list</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>Pgsql-ayuda@tlali.iztacala.unam.mx</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>http://tlali.iztacala.unam.mx/mailman/listinfo/pgsql-ayuda</FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I></FONT></FONT></I>
<FONT COLOR="#474073"><FONT SIZE="3"><I>End of Pgsql-ayuda Digest</FONT></FONT></I>
</PRE>
    </BLOCKQUOTE>
</BODY>
</HTML>

--=-iwlh3UXSAevths4Z/w+p--