Re: PgSQL and integration between 2 PHP programs and a Java program

Поиск
Список
Период
Сортировка
От Juan Miguel Paredes
Тема Re: PgSQL and integration between 2 PHP programs and a Java program
Дата
Msg-id 9e0a28690611091347ie22a1cds7c4092f870bf50cd@mail.gmail.com
обсуждение исходный текст
Ответ на Re: PgSQL and integration between 2 PHP programs and a Java program  ("Servers24 Network" <servers24@gmail.com>)
Список pgsql-php
Hi, folks!

On 11/9/06, Servers24 Network <servers24@gmail.com> wrote:
> This was the description of my project. If anyone have a better solution
> please let me know. I also have researched about using LDAP as the main DB
> server but seems it can only be used as the CAS and not the main DB for
> applications as it's main use is as a directory and can not be used in a
> high volume of changing data environment. Also very much modification should
> be done in each application to be able to talk to LDAP server!!

PHP can take advantage of php4-ldap/php5-ldap to communicate with LDAP
server with no much trouble... Of course, that depends on your actual
class design, but with good OO design it should be quite simple to
replace/extend existing classes/methods for LDAP.  Same thing could be
said for Java.

> Also I have another question : do I need to edit MySQL queries very much in
> my PHP applications to interact with a PgSQL or not? Because most of the
> queries are the same and maybe very few should be changed ( as far as I
> know! ).

Again, if you're using some ORM or database abstraction layer
(PHP-ADODB, for example of the latter), it could be as simple as
changing your dsn configuration with maybe a very few noticeable
differences in sql-dialects.  If you're using just plain old php
database apis (e.g. mysql_connect, mysql_query), both mysql and pgsql
apis are very similar in php (there's mysql_connect for pg_connect,
mysql_query for pg_query and so on)...  Just watch out for things like
parameter ordering and so on (documentation is your friend), but of
course, database abstraction is highly recommended.

In any case, LDAP could be a good option for storing authentication
and authorization information in a centralized repository (most modern
frameworks, languages, technologies can integrate pretty well with
LDAP), and keep your application-specific data in whatever repository
seems appropiate.

Greetings!

В списке pgsql-php по дате отправления:

Предыдущее
От: "Servers24 Network"
Дата:
Сообщение: Re: PgSQL and integration between 2 PHP programs and a Java program
Следующее
От: Brew
Дата:
Сообщение: Re: PgSQL and integration between 2 PHP programs and a Java program