note 120705 deleted from pdo.construct by cmb
| From: | cmb@php.net | Date: | Mon, 28 Sep 2020 13:28:36 +0000 |
| Subject: | note 120705 deleted from pdo.construct by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-215480@lists.php.net to get a copy of this message | ||
Note Submitter: tomolimo at gmail dot com
----
Just to give an odbc string connection example to MSSQL:
$odbc="odbc:Driver={SQL Server};Server=$server;Database=$database;";
$cnx = new PDO( $odbc , $user, $password);
$sql="SELECT field FROM Quotation_Header WHERE (field> 0)";
foreach ($cnx->query($sql) as $row) {
echo $row['field'] . "\n";
}