Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 92CA19FB395 for ; Sun, 29 Apr 2007 04:40:42 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 85486-05 for ; Sun, 29 Apr 2007 04:40:39 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from sd-2317.dedibox.fr (sd-2317.dedibox.fr [88.191.17.192]) by postgresql.org (Postfix) with ESMTP id 4212A9FB30D for ; Sun, 29 Apr 2007 04:40:39 -0300 (ADT) Received: from sd-2317.dedibox.fr (localhost.localdomain [127.0.0.1]) by sd-2317.dedibox.fr (Postfix) with ESMTP id 1FDC610163; Sun, 29 Apr 2007 09:44:04 +0200 (CEST) Received: from [192.168.10.64] (ASte-Genev-Bois-153-1-98-158.w90-3.abo.wanadoo.fr [90.3.184.158]) by sd-2317.dedibox.fr (Postfix) with ESMTP id D94A71015D; Sun, 29 Apr 2007 09:44:03 +0200 (CEST) Message-ID: <46344BED.4000801@lelarge.info> Date: Sun, 29 Apr 2007 09:40:29 +0200 From: Guillaume Lelarge User-Agent: Thunderbird 2.0.0.0 (X11/20070326) MIME-Version: 1.0 To: Richard Dunne CC: pgsql-php@postgresql.org Subject: Re: Fw: select * from table not showing everything References: <209777.36134.qm@web50311.mail.re2.yahoo.com> In-Reply-To: <209777.36134.qm@web50311.mail.re2.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200704/12 X-Sequence-Number: 3789 Richard Dunne a écrit : > I am still at a loss. I deleted everything from the table using > delete from table; > I then added a row using the php method with the php webpage. I then checked the table with > select * from table; > > this being the result > > > name | address | contact_no > ------+---------+------------ > | | > (1 row) > > As you can see its detecting an entry in the table but it is not displaying the entry. > Can anyone advise? I am only geussing at a configuration problem? > Perhaps because empty strings were send. You're not telling us your PHP version. If you have 4.2.0 or later, register_globals is by default disabled and $customer_name, $customer_address and $customer_contact_no won't be registered. You'll need to use $_GET array to get those values. Moreover, you don't escape strings. Maybe you should try this $query = "insert into customer values("; $query .= "'" . pg_escape_string($_GET['customer_name']) . "', "; $query .= "'" . pg_escape_string($_GET['customer_address']) . "', "; $query .= "'" . pg_escape_string($_GET['customer_contact_no']) . "')"; $result = pg_query($connect, $query); and read this http://www.php.net/language.variables.predefined Regards. -- Guillaume.