RPMs for PHP accessing PostgreSQL via ODBC over

RPMs for PHP accessing PostgreSQL via ODBC over

Post by Michael Fo » Wed, 07 Mar 2001 07:53:13



Just FYI, but PHP can be used to talk to a remote postgres server using
native postgres calls, i.e.:

$conn = pg_connect("host=some.host.com user=me password=i db=test");
pg_exec($conn, "SELECT * FROM pg_class");
pg_close($conn);

Michael Fork - CCNA - MCP - A+
Network Support - Toledo Internet Access - Toledo Ohio


> >Is it really necessary to use PHP and ODBC? PHP has a native postgresql
> >interface I believe...

> It sounds like the postgres server is a different machine to the web
> server, so ODBC is needed to communicate between the 2..
> I have no answer for that unfortunately :(
> This url *might* be of use - http://www.php.net/manual/en/ref.odbc.php

> Let us know how you go & what you did :)

> >>Hi,
> >>We are currently running the following configuration on our server:
> >>Linux Red Hat 7.0
> >>PostgreSQL 7.1beta4-1
> >>PHP 4.0.1pl2
> >>I need to add some RPM package (or perhaps an apache module) to enable PHP
> >>to access PostgreSQL via ODBC.
> >>In order to have PostgreSQL native access support we installed package
> >>'php-pgsql-4.0.1pl2-9.i386.rpm'.
> >>Is there some similar RPM package to enable ODBC access in PHP4.0.1pl2?
> >>If not, how should I procceed?
> >>TIA,
> >>Paulo

> ------------------------
> Chris Smith
> http://www.squiz.net

> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command


---------------------------(end of broadcast)---------------------------

 
 
 

RPMs for PHP accessing PostgreSQL via ODBC over

Post by Brett W. McCo » Wed, 07 Mar 2001 08:15:12



> >Is it really necessary to use PHP and ODBC? PHP has a native postgresql
> >interface I believe...

> It sounds like the postgres server is a different machine to the web
> server, so ODBC is needed to communicate between the 2..

No it isn't.  Postgres should be accessible via PHP whether it's on the
same server or on a remote server (and Postgres is configured to allow
remote access).  The only reason I can guess as to why ODBC is being used
is to perhaps maintain code compatibility with the use of a different
databse platform that the web server may have been using previously.

-- Brett

                                http://www.chapelperilous.net/~bmccoy/
------------------------------------------------------------------------
I didn't get sophisticated -- I just got tired.  But maybe that's what
sophisticated is -- being tired.
                -- Rita Gain

---------------------------(end of broadcast)---------------------------


 
 
 

1. [PHP] RPMs for PHP accessing PostgreSQL via ODBC over RedHat

Hi,

We are currently running the following configuration on our server:

Linux Red Hat 7.0
PostgreSQL 7.1beta4-1
PHP 4.0.1pl2

I need to add some RPM package (or perhaps an apache module) to enable PHP
to access PostgreSQL via ODBC.

In order to have PostgreSQL native access support we installed package
'php-pgsql-4.0.1pl2-9.i386.rpm'.

Is there some similar RPM package to enable ODBC access in PHP4.0.1pl2?

If not, how should I procceed?

TIA,
Paulo

---------------------------(end of broadcast)---------------------------

2. DTS/Login Copy to SQL 7 to 2000

3. RPMs for PHP accessing PostgreSQL via ODBC

4. pgsql/src/backend/catalog index.c

5. RPMs for PHP accessing PostgreSQL via ODBC over RedHat

6. What is DB-Steward?

7. [PHP] PostgreSQL + PHP + SQL warning messages

8. PHP+MySQL vs. PHP+PostgreSQL

9. Problem with ODBC Connection to DB2 via PHP

10. Connect PHP with Progress via OIB/OID/ using ODBC for SQL89

11. ASP or PHP with FMP 5 via ODBC

12. inserting date or timestamp in db2 with php via ODBC