<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/refs.database.abstract.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'it',
  ),
  'this' => 
  array (
    0 => 'book.pdo.php',
    1 => 'PDO',
    2 => 'PHP Data Objects',
  ),
  'up' => 
  array (
    0 => 'refs.database.abstract.php',
    1 => 'Livelli d\'Astrazione',
  ),
  'prev' => 
  array (
    0 => 'function.odbc-tables.php',
    1 => 'odbc_tables',
  ),
  'next' => 
  array (
    0 => 'pdo.setup.php',
    1 => 'Installazione/Configurazione',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/pdo/book.xml',
  ),
  'history' => 
  array (
  ),
  'extra_header_links' => 
  array (
    'rel' => 'alternate',
    'href' => '/manual/en/feeds/book.pdo.atom',
    'type' => 'application/atom+xml',
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="book.pdo" class="book">
 
 <h1 class="title">PHP Data Objects</h1>
 

 
 <div id="intro.pdo" class="preface">
  <h1 class="title">Introduzione</h1>
  <p class="para">
   The <code class="literal">PHP Data Objects</code> (<abbr title="PHP Data Objects">PDO</abbr>) extension defines a lightweight, consistent interface
   for accessing databases in PHP. Each database driver that
   implements the PDO interface can expose database-specific
   features as regular extension functions. Note that you cannot
   perform any database functions using the PDO extension by
   itself; you must use a <a href="pdo.drivers.php" class="link">database-specific
   PDO driver</a> to access a database server.
  </p>
  <p class="para">
   PDO provides a <em>data-access</em> abstraction layer, which
   means that, regardless of which database you&#039;re using, you use the same
   functions to issue queries and fetch data.  PDO does
   <em>not</em> provide a <em>database</em>
   abstraction; it doesn&#039;t rewrite SQL or emulate missing features.  You
   should use a full-blown abstraction layer if you need that facility.
  </p>
  <p class="para">
   PDO ships with PHP.
  </p>
 </div>
 

 







 






 





 

 







 







 







 








 




 




 



 





 







<ul class="chunklist chunklist_book"><li><a href="pdo.setup.php">Installazione/Configurazione</a><ul class="chunklist chunklist_book chunklist_children"><li><a href="pdo.installation.php">Installazione</a></li><li><a href="pdo.configuration.php">Configurazione di Runtime</a></li></ul></li><li><a href="pdo.constants.php">Costanti predefinite</a><ul class="chunklist chunklist_book chunklist_children"><li><a href="pdo.constants.fetch-modes.php">Fetch Modes</a></li></ul></li><li><a href="pdo.connections.php">Connections and Connection management</a></li><li><a href="pdo.transactions.php">Transactions and auto-commit</a></li><li><a href="pdo.prepared-statements.php">Prepared statements and stored procedures</a></li><li><a href="pdo.error-handling.php">Errors and error handling</a></li><li><a href="pdo.lobs.php">Large Objects (LOBs)</a></li><li><a href="class.pdo.php">PDO</a> — The PDO class<ul class="chunklist chunklist_book chunklist_children"><li><a href="pdo.begintransaction.php">PDO::beginTransaction</a> — Initiates a transaction</li><li><a href="pdo.commit.php">PDO::commit</a> — Commits a transaction</li><li><a href="pdo.connect.php">PDO::connect</a> — Connect to a database and return a PDO subclass for drivers that support it</li><li><a href="pdo.construct.php">PDO::__construct</a> — Creates a PDO instance representing a connection to a database</li><li><a href="pdo.errorcode.php">PDO::errorCode</a> — Fetch the SQLSTATE associated with the last operation on the database handle</li><li><a href="pdo.errorinfo.php">PDO::errorInfo</a> — Fetch extended error information associated with the last operation on the database handle</li><li><a href="pdo.exec.php">PDO::exec</a> — Execute an SQL statement and return the number of affected rows</li><li><a href="pdo.getattribute.php">PDO::getAttribute</a> — Retrieve a database connection attribute</li><li><a href="pdo.getavailabledrivers.php">PDO::getAvailableDrivers</a> — Return an array of available PDO drivers</li><li><a href="pdo.intransaction.php">PDO::inTransaction</a> — Checks if inside a transaction</li><li><a href="pdo.lastinsertid.php">PDO::lastInsertId</a> — Returns the ID of the last inserted row or sequence value</li><li><a href="pdo.prepare.php">PDO::prepare</a> — Prepares a statement for execution and returns a statement object</li><li><a href="pdo.query.php">PDO::query</a> — Prepares and executes an SQL statement without placeholders</li><li><a href="pdo.quote.php">PDO::quote</a> — Quotes a string for use in a query</li><li><a href="pdo.rollback.php">PDO::rollBack</a> — Rolls back a transaction</li><li><a href="pdo.setattribute.php">PDO::setAttribute</a> — Set an attribute</li></ul></li><li><a href="class.pdostatement.php">PDOStatement</a> — The PDOStatement class<ul class="chunklist chunklist_book chunklist_children"><li><a href="pdostatement.bindcolumn.php">PDOStatement::bindColumn</a> — Bind a column to a PHP variable</li><li><a href="pdostatement.bindparam.php">PDOStatement::bindParam</a> — Binds a parameter to the specified variable name</li><li><a href="pdostatement.bindvalue.php">PDOStatement::bindValue</a> — Binds a value to a parameter</li><li><a href="pdostatement.closecursor.php">PDOStatement::closeCursor</a> — Closes the cursor, enabling the statement to be executed again</li><li><a href="pdostatement.columncount.php">PDOStatement::columnCount</a> — Returns the number of columns in the result set</li><li><a href="pdostatement.debugdumpparams.php">PDOStatement::debugDumpParams</a> — Dump an SQL prepared command</li><li><a href="pdostatement.errorcode.php">PDOStatement::errorCode</a> — Fetch the SQLSTATE associated with the last operation on the statement handle</li><li><a href="pdostatement.errorinfo.php">PDOStatement::errorInfo</a> — Fetch extended error information associated with the last operation on the statement handle</li><li><a href="pdostatement.execute.php">PDOStatement::execute</a> — Executes a prepared statement</li><li><a href="pdostatement.fetch.php">PDOStatement::fetch</a> — Fetches the next row from a result set</li><li><a href="pdostatement.fetchall.php">PDOStatement::fetchAll</a> — Fetches the remaining rows from a result set</li><li><a href="pdostatement.fetchcolumn.php">PDOStatement::fetchColumn</a> — Returns a single column from the next row of a result set</li><li><a href="pdostatement.fetchobject.php">PDOStatement::fetchObject</a> — Fetches the next row and returns it as an object</li><li><a href="pdostatement.getattribute.php">PDOStatement::getAttribute</a> — Retrieve a statement attribute</li><li><a href="pdostatement.getcolumnmeta.php">PDOStatement::getColumnMeta</a> — Returns metadata for a column in a result set</li><li><a href="pdostatement.getiterator.php">PDOStatement::getIterator</a> — Gets result set iterator</li><li><a href="pdostatement.nextrowset.php">PDOStatement::nextRowset</a> — Advances to the next rowset in a multi-rowset statement handle</li><li><a href="pdostatement.rowcount.php">PDOStatement::rowCount</a> — Returns the number of rows affected by the last SQL statement</li><li><a href="pdostatement.setattribute.php">PDOStatement::setAttribute</a> — Set a statement attribute</li><li><a href="pdostatement.setfetchmode.php">PDOStatement::setFetchMode</a> — Set the default fetch mode for this statement</li></ul></li><li><a href="class.pdorow.php">PDORow</a> — The PDORow class</li><li><a href="class.pdoexception.php">PDOException</a> — The PDOException class</li><li><a href="pdo.drivers.php">PDO Drivers</a><ul class="chunklist chunklist_book chunklist_children"><li><a href="ref.pdo-cubrid.php">CUBRID PDO Driver</a> — CUBRID PDO Driver (PDO_CUBRID)</li><li><a href="ref.pdo-dblib.php">MS SQL Server PDO Driver</a> — Microsoft SQL Server and Sybase PDO Driver (PDO_DBLIB)</li><li><a href="class.pdo-dblib.php">Pdo\Dblib</a> — The Pdo\Dblib class</li><li><a href="ref.pdo-firebird.php">Firebird PDO Driver</a> — Firebird PDO Driver (PDO_FIREBIRD)</li><li><a href="class.pdo-firebird.php">Pdo\Firebird</a> — The Pdo\Firebird class</li><li><a href="ref.pdo-ibm.php">IBM PDO Driver</a> — IBM PDO Driver (PDO_IBM)</li><li><a href="ref.pdo-informix.php">Informix PDO Driver</a> — Informix PDO Driver (PDO_INFORMIX)</li><li><a href="ref.pdo-mysql.php">MySQL PDO Driver</a> — MySQL PDO Driver (PDO_MYSQL)</li><li><a href="class.pdo-mysql.php">Pdo\Mysql</a> — The Pdo\Mysql class</li><li><a href="ref.pdo-sqlsrv.php">MS SQL Server PDO Driver</a> — Microsoft SQL Server PDO Driver (PDO_SQLSRV)</li><li><a href="ref.pdo-oci.php">Oracle PDO Driver</a> — Oracle PDO Driver (PDO_OCI)</li><li><a href="ref.pdo-odbc.php">ODBC and DB2 PDO Driver</a> — ODBC and DB2 PDO Driver (PDO_ODBC)</li><li><a href="class.pdo-odbc.php">Pdo\Odbc</a> — The Pdo\Odbc class</li><li><a href="ref.pdo-pgsql.php">PostgreSQL PDO Driver</a> — PostgreSQL PDO Driver (PDO_PGSQL)</li><li><a href="class.pdo-pgsql.php">Pdo\Pgsql</a> — The Pdo\Pgsql class</li><li><a href="ref.pdo-sqlite.php">SQLite PDO Driver</a> — SQLite PDO Driver (PDO_SQLITE)</li><li><a href="class.pdo-sqlite.php">Pdo\Sqlite</a> — The Pdo\Sqlite class</li></ul></li></ul></div><?php manual_footer($setup); ?>