Home > Backend Development > PHP Tutorial > php mssql database connection code_PHP tutorial

php mssql database connection code_PHP tutorial

WBOY
Release: 2016-07-13 17:04:25
Original
865 people have browsed it

php tutorial mssql database tutorial connection code

$conn=ADONewConnection('odbc_mssql');
$conn->PConnect("Driver={SQL Server};Server=DLUT-PCSQLEXPRESS;Database=yuyan;",'zhouhao','950288');
$ADODB_FETCH_MODE=ADODB_FETCH_ASSOC;
$sqlstr='select * from yuyan where ps tutorialnNo=?';
$rst=$conn->execute($sqlstr,'005') or die('connect error');
while(!$rst->EOF)
{
//echo $rst->fields['psnName'].'->'.$rst->fields['www.bKjia.c0m'].'';
echo 'dajiahao';
$rst->movenext();
}
$rst->close();
$conn->close();

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/630863.htmlTechArticlephp tutorial mssql database tutorial connection code $conn=ADONewConnection('odbc_mssql'); $conn-PConnect(Driver= {SQL Server};Server=DLUT-PCSQLEXPRESS;Database=yuyan;,'zhouhao','950288'); $A...
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template