|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2000-06-16 16:46 UTC] kara at cvs dot php dot net
[2000-06-16 17:29 UTC] bill_hardeman at adventure dot com
[2000-08-01 23:11 UTC] waldschrott@php.net
[2000-08-12 03:27 UTC] ahill@php.net
[2000-08-20 02:34 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Nov 03 01:00:01 2025 UTC |
In PHP3, the odbc_do or odbc_exec worked fine in this script. With PHP4, the only way to get the script to work is to run odbc_prepare and odbc_execute. <HEAD> <TITLE> NetWork MSSQL Database </TITLE> </HEAD> <BODY BGCOLOR=white> <? $dsn = "dsn=clientele"; $odbcuser = "ctel"; $odbcpasswd = ""; $odbcCurType = "SQL_CUR_DEFAULT"; /* Create the connection */ $odbc_connect_id = odbc_connect($dsn, $odbcuser, $odbcpasswd, $odbcCurType); $sql_query = "SELECT * FROM clientele.ctel.techfullname"; // $result = odbc_do($odbc_connect_id, $sql_query); /* failed */ // $result = odbc_exec($odbc_connect_id, $sql_query); /* failed */ // this works $result_id = odbc_prepare($odbc_connect_id, $sql_query); odbc_execute($result_id); odbc_result_all($result_id, "border=3"); ?> </BODY> </HTML>