Skip site navigation (1) Skip section navigation (2)

Re: pg_query undefined?

From: Gerd Terlutter <gerd(at)MplusB(dot)de>
To: pgsql-php(at)postgresql(dot)org
Cc: rhunter(at)venticon(dot)com
Subject: Re: pg_query undefined?
Date: 2003-07-13 13:59:36
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-php
Hi all,
best to use for simple statements is PEAR::DB. you can write code 
abstract. i found this out while convert a DB from mysql to pgsql, now 
we'll wrap table and field names. then we are always sureto write 
universal code. the problem was the following:
mysql table and field names are sometimes uppercase
while converting with all names changed to lowercase
alterante: quote tables and fields, but then quote it in your code to. 
if you try to run this quoted code on mysql you'll get errors.
when we have all wrapped, i hope it will run under several RDBMS.
excuse my bad english, it's to long ago i learned it and not often spoken.
have fun, Gerd

Ray Hunter wrote:
> Also make sure that pgsql is installed in php. By checking the phpinfo()
> function u can verify your php version (4.2+) and if pgsql has been
> compiled into php. 
> If you have 4.2 or higher than u might need to compile pgsql into php.
> --
> Ray
> On Sat, 2003-07-12 at 16:54, Lynna Landstreet wrote:
>>Does anyone know why trying to run a simple demo script (the one that came
>>with EZ_SQL from would be giving me an error saying
>>that pg_query() is an undefined function? It's a standard function built
>>into PHP, isn't it? It's listed in the manual...
>>I know the installation of PHP at our web host does have PostgreSQL support,
>>because when I ran phpinfo() it seemed to say all the right things about it,
>>so this is really confusing me.
# Gerd Terlutter        | Mueller+Blanck Software GmbH #
# gerd(at)MplusB(dot)de        | Gutenbergring 38             #
# gerd(dot)terlutter(at)web(dot)de | D-22848 Noderstedt           #
# tel:0171/6992579      | tel:+49 40 500 171-1         #
# Buero:040/500171-17   | fax:+49 40 500 171-71        #

In response to

pgsql-php by date

Next:From: Davi LealDate: 2003-07-14 19:10:14
Subject: postgreSQL web form; Security
Previous:From: Ray HunterDate: 2003-07-13 06:00:12
Subject: Re: pg_query undefined?

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group