Re: Problemas con PHP y SQL

From: Date: Wed, 27 Sep 2000 12:39:45 +0000
Subject: Re: Problemas con PHP y SQL
References: 1  Groups: php.general.es 
Request: Send a blank email to general-es+get-1946@lists.php.net to get a copy of this message
Hola Sergi & *: On Wed, 27 Sep 2000, "Sergi Aumatell i Ramírez" wrote: >Tengo esta 'select': > > select count(*) > from EMPRESA A, USUARIO B > where A.NUM=B.NUM > AND A.COD = 'GRP'"; > >y cuando la ejecuto me da el siguiente error. > >"Warning: SQL error: [Microsoft][ODBC driver for Oracle][Oracle]ORA-00918: column >ambiguously defined, SQL state NA000 in SQLExecDirect in c:\inetpub\wwwroot/php/_sergi/usuarios.php3 >on line 14 >Error in odbc_exec( no cursor returned )" El count generalmente se debe usar refiriendose a una columna en especifico, es decir, a un valor puntual. Por ejemplo: select count(a.num) from empresa a... Saludos, -- Luis R. Sales Gonzalez WebMaster Sony Latin America mailto: lrsg@intradev.sola.sony.com

« previous php.general.es (#1946) next »