Probably a dumb question but I'm new to PEAR.
| From: | Malcolm Turnbull | Date: | Wed, 20 Mar 2002 15:42:04 +0000 |
| Subject: | Probably a dumb question but I'm new to PEAR. | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-987@lists.php.net to get a copy of this message | ||
Howdy,
I'd like to set up an intranet system that can use either a PostGreSQL
backend (prefered) or a MSSQL7 one if I run in to trouble( being a newbie to
PostGreSQL)..
PHP postgres functions work fine, but I'd like to use PEAR DB to make life
easier (Ha!)
I'm running Mandrake 7.1, PHP 4.06 & PostGreSQL 7.2
I've grabbed the PEAR files from the latest PHP 4.1.2 tar ball (as mandrake
doesn't include them)
and put them in the include path..
Now I've tested :
$db=DB::connect($dsn);
and this connects fine with no errors.
$db->disconnect();
also works fine...
BUT anything inbetween causes a parser error ?
i.e.
$sql=("select * from users2;");
$result=$db->query($sql);
will cause PARSE ERROR on line.....
What am I doing wrong ?
Thanks in advance.
Regards,
Malcolm Turnbull
www.crocus.co.uk - For all your Garden Needs
www.stealthinventory.com - The Open Source Software Audit Tool
01344 629661
07715 770523