> We have a host (host A) with PostgreSQL 7.0.3. and PHP 4.0.4 under Red Hat
>
> We have another host (host B) with PHP 4.0.3pl1 under Debian
>
> We are having an incomprehensible error with this code when the content of
$sql is
>
> and "update"
>
> ...
>
> $resultado=pg_Exec($conexion,$sql);
>
> ...
>
> 1) The php code from host A works ok.
>
> 2) The same php code from host B accessing postgresql database on host A
>
> does not work with "update", but it works with "select", "insert", and
"delete".
>
> 3) If I try from host B: psql -h hostA -d database -u
>
> update fam set nom='xxxxxx' where id='23'
>
> it works ok.
>
> 4) So, where is the problem? php4 libraries under Debian distribution?
Any chance the user permissions are disallowing an update from host B?...
Or are you actually using the same username/password when you do it in the
psql monitor? [I tend to use my 'real' Postgres account in the monitor and
the 'restricted' one in my PHP pages... But maybe that's just my own folly.
:-) ]
pg_exec() usually sends an error when something goes wrong... Is your
error_reporting() set to 15? Better yet, use pg_errormessage() to see if
maybe you can dig something out of that.
If all that fails, I'd suggest searching http://bugs.php.net and posting
there if it's not a known bug.
--
Visit the Zend Store at http://www.zend.com/store/
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]