Quantcast
Channel: WampServer - WampServer English
Viewing all articles
Browse latest Browse all 3177

PHP odbc_connect doesn't... when via DSN (no replies)

$
0
0
I have an ODBC Connection that works:

$cqmconn = odbc_connect("Driver={SQL Server Native Client 10.0}; Server=JOHN-HP; Database=cqmla;", "sa", "sa") or die ("Unable to connect to CQM site.");

However, I have an existing ODBC Driver called "cqm2" that connects to cqmla, but the line below does NOT make a connection (with or without the "SQL_CUR_USE_ODBC")

$cqmconn = odbc_connect("cqm2","sa","sa", SQL_CUR_USE_ODBC) or die ("Unable to connect to CQM site.")

I can, however, use that ODBC connection (and credentials) with Visual FoxPro and the DSN connection works fine. What am I missing?

I ask this because while I certainly can use the first method here, I have ANOTHER proprietary system that I cannot get to work, although it does have an ODBC connection I can access via other software using the: $cqmconn = odbc_connect("cqm2","sa","sa") format. If I can get my existing connection to work here, I figure I should then be able to call the other one.

What am I missing? Thanks in advance!
PS: For some reason, this page is putting my close parentheses in as smiley faces!
-- John Kiernan

Viewing all articles
Browse latest Browse all 3177

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>