PDOStatement::debugDumpParams

Microsoft Drivers for PHP for SQL Server

Collapse image Expand Image Copy image CopyHover image

Displays a prepared statement.

Syntax

bool PDOStatement::debugDumpParams();

Remarks

Support for PDO was added in version 2.0 of the Microsoft Drivers for PHP for SQL Server.

Example

  Copy imageCopy Code
<?php
$database = "AdventureWorks";
$server = "(local)";
$conn = new PDO( "sqlsrv:server=$server ; Database = $database", "", "");

$param = "Owner";

$stmt = $conn->prepare("select * from Person.ContactType where name = :param");
$stmt->execute(array($param));
$stmt->debugDumpParams();

echo "\n\n";

$stmt = $conn->prepare("select * from Person.ContactType where name = ?");
$stmt->execute(array($param));
$stmt->debugDumpParams();
?>

See Also

Reference

Other Resources

PDO