v5:database:mysql
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
v5:database:mysql [2016/03/20 00:51] – mnewnham | v5:database:mysql [2023/05/10 09:41] – [mysqli driver] mysqlnd required since 5.22 dregad | ||
---|---|---|---|
Line 2: | Line 2: | ||
~~NOTOC~~ | ~~NOTOC~~ | ||
===== mysqli driver ===== | ===== mysqli driver ===== | ||
+ | |||
<WRAP right box round 300px> | <WRAP right box round 300px> | ||
+ | |||
== Specification == | == Specification == | ||
^Driver Name|mysqli| | ^Driver Name|mysqli| | ||
- | ^Data Provider|mysql| | + | ^Data Provider|[[v5: |
^Status|Active((This driver is actively supported by ADOdb project members))| | ^Status|Active((This driver is actively supported by ADOdb project members))| | ||
^Windows|Yes| | ^Windows|Yes| | ||
Line 11: | Line 13: | ||
^ADOdb V5|Yes| | ^ADOdb V5|Yes| | ||
^ADOdb V6|Yes| | ^ADOdb V6|Yes| | ||
+ | |||
== Alternatives == | == Alternatives == | ||
[[v5: | [[v5: | ||
+ | |||
+ | == See Also == | ||
+ | [[v5: | ||
</ | </ | ||
Line 20: | Line 26: | ||
* [[http:// | * [[http:// | ||
- | This preferred | + | This driver uses the PHP **mysqli** interface and supports all table types, with full support for transactions and rollback when the table type supports it. |
- | This driver | + | It replaces |
- | -------------------------------------- | + | |
- | ===== mysql driver ===== | + | < |
- | < | + | Starting with ADOdb 5.22, the mysqli driver requires the [[https:// |
- | == Specification == | + | |
- | ^Driver | + | |
- | ^Data Provider|mysql)| | + | |
- | ^Status|Obsolete((This driver will be removed in ADOdb version 6))| | + | |
- | ^Windows|Yes| | + | |
- | ^Unix|Yes| | + | |
- | ^ADOdb V5|Yes| | + | |
- | ^ADOdb V6|No| | + | |
</ | </ | ||
- | This driver uses the PHP original mysql driver and only provides support to non-transactional tables such as MyIsam. It cannot be used with the PHP ' | ||
- | ----------------------------------------------------- | ||
- | If you are still using this driver (or the mysqlt driver derived from it) you should be planning on migrating to the mysqli driver. Support for both drivers is built into PHP up to version PHP 5.4. From an ADOdb standpoint, it is simply a case of switching from | ||
+ | ------------------------------------------- | ||
- | $db = newAdoConnection(' | ||
- | to | ||
- | $db = newAdoConnection(' | ||
- | |||
- | ----------------------------------------------- | ||
- | ===== mysqlt driver ===== | ||
- | <WRAP right box round 300px> | ||
- | == Specification == | ||
- | ^Driver Name|mysqlt| | ||
- | ^Data Provider|mysql)| | ||
- | ^Status|Obsolete((This driver will be removed in ADOdb version 6))| | ||
- | ^Windows|Yes| | ||
- | ^Unix|Yes| | ||
- | ^ADOdb V5|Yes| | ||
- | ^ADOdb V6|No| | ||
- | </ | ||
- | This driver uses the PHP original mysql driver and provided support to transactional tables such as InnoDB. It cannot be used with the PHP ' | ||
- | -------------------------------- | ||
- | ===== mysqlpo driver ===== | ||
- | <WRAP right box round 300px> | ||
- | == Specification == | ||
- | ^Driver Name|mysqlpo| | ||
- | ^Data Provider|mysql)| | ||
- | ^Status|Obsolete((This driver will be removed in ADOdb version 6))| | ||
- | ^Windows|Yes| | ||
- | ^Unix|Yes| | ||
- | ^ADOdb V5|Yes| | ||
- | ^ADOdb V6|No| | ||
- | </ | ||
- | This driver duplicates the functionality of the mysqlt driver and is not maintained. It will be removed in ADOdb version 6.0 | ||
- | ------------------------------------------ | ||
===== Driver Specific Issues ===== | ===== Driver Specific Issues ===== | ||
==== renameColumnSql ==== | ==== renameColumnSql ==== | ||
Line 88: | Line 52: | ||
$sql = $dict-> | $sql = $dict-> | ||
- | </ | + | </ |
- | {{tag> | + | ==== Connecting With SSL ==== |
+ | From ADOdb version 5.21, you can make an SSL connection to MySQL in the following way: | ||
+ | |||
+ | <code php> | ||
+ | /* | ||
+ | * Enable ADOdb | ||
+ | */ | ||
+ | $db = newAdoConnection(' | ||
+ | /* | ||
+ | * Set the SSL parameters | ||
+ | */ | ||
+ | $db-> | ||
+ | $db-> | ||
+ | $db-> | ||
+ | $db-> | ||
+ | $db-> | ||
+ | |||
+ | /* | ||
+ | * Open the connection | ||
+ | */ | ||
+ | $db-> | ||
+ | </ | ||
+ | |||
+ | ==== Connecting To A Microsoft Azure MySQL Instance ==== | ||
+ | <code php> | ||
+ | /* | ||
+ | * Enable ADOdb | ||
+ | */ | ||
+ | $db = newAdoConnection(' | ||
+ | |||
+ | $database = ' | ||
+ | $host = ' | ||
+ | $user = ' | ||
+ | $password = ' | ||
+ | |||
+ | $db-> | ||
+ | |||
+ | /* | ||
+ | * Open the connection | ||
+ | */ | ||
+ | $db-> | ||
+ | </ | ||
+ | |||
+ | {{tag> | ||
+ | {{htmlmetatags> |
v5/database/mysql.txt · Last modified: 2024/04/30 13:07 by dregad