ODBC or native functions?

This is a discussion on ODBC or native functions? within the PHP Language forums, part of the PHP Programming Forums category; Hi, I am new to MySQL and PHP programming. What is the practical difference between MySQL ODBC functions (3.51 ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-01-2005
Marek Kotowski
 
Posts: n/a
Default ODBC or native functions?

Hi,

I am new to MySQL and PHP programming.
What is the practical difference between MySQL
ODBC functions (3.51 Driver) and native mysql
support in PHP (I mean "mysql_" functions available in PHP)?
(the same question applies to PostgreSQL native functions).

Which functions to prefer, in general and in specific situations?

Thank you in advance.

Marek Kotowski
Warsaw
Reply With Quote
  #2 (permalink)  
Old 03-01-2005
NC
 
Posts: n/a
Default Re: ODBC or native functions?

Marek Kotowski wrote:
>
> What is the practical difference between MySQL
> ODBC functions (3.51 Driver) and native mysql
> support in PHP (I mean "mysql_" functions available in PHP)?


ODBC is designed for connectivity. If you declare your
database as an ODBC source, any program that understands
ODBC can interact with your database without even knowing
it is in fact a MySQL database.

Native support, in contrast, is designed for performance.
Without an additional middleware layer, databases can be
more robust.

> Which functions to prefer, in general and in specific
> situations?


When writing PHP/MySQL applications, there is no compelling
reason to use ODBC. ODBC is a Windows-centric technology,
and you don't see a lot of people running PHP applications
on Windows. Most Web hosting providers run on either BSD
or Linux and do not provide ODBC functionality.

You may need ODBC if you are working with less common
database engines (Adabas, SAP DB, DB2, etc.) that do not
have native support in PHP.

Cheers,
NC

Reply With Quote
  #3 (permalink)  
Old 03-02-2005
Marek Kotowski
 
Posts: n/a
Default Re: ODBC or native functions?

"NC" <nc@iname.com> wrote in message news:<1109699365.794294.5200@g14g2000cwa.googlegro ups.com>...
[...]
> You may need ODBC if you are working with less common
> database engines (Adabas, SAP DB, DB2, etc.) that do not
> have native support in PHP.
>
> Cheers,
> NC


Thank you.
Regards

Marek Kotowski
Warsaw
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 10:56 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0