You are here: Re: Access to different database types « PHP Programming Language « IT news, forums, messages
Re: Access to different database types

Posted by Oliver Grätz on 03/26/07 08:10

scott.alfon@gmx.de schrieb:
> I want to implement a php-script where I can access to different
> database types as PostSQL, MySQL etc.
> Is that possible? Furthermore I want to include an access
> authorization which defines the write- or read-access of each user.

Yes it is possible and has already been solved a couple of times. Don't
waste time on reimplementing this but reside to using one of the
existing solutions like AdoDb or PEAR_DB. Using PDO already makes it
possible to access different DBMS but you have to write your SQL so that
it is accepted by all the DBMS you plan on using. For example, the code

id INTEGER AUTO_INCREMENT

will only work in a CREATE when using MySQL since most other DBMS have
another way of declaring auto-incrementing identifier columns.

Furthermore, you might want to use some ORM solution like Propel or one
of the solutions in the different frameworks depending on the nature of
your projects.

OLLi

--
"What’s a little treason between old friends?"
[Jack, Alias 508]

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация