Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ODBC API Calls SQLTables/SQL Columns

Status
Not open for further replies.

pcawdron

Programmer
Jun 14, 2000
109
AU
Does anyone have any Visual Basic code that calls the ODBC API functions SQLTables and SQL Columns.&nbsp;&nbsp;<br><br>Or, alternatively, does anyone know where I can find an exaustive list of all the various ODBC API constants?&nbsp;&nbsp;The file ODBC32.TXT from Mircosoft is not up to date.&nbsp;&nbsp;It's missing constants like SQL_ALL_CATALOGS.<br><br>Microsoft has such a unique way of providing incredibly detailed information on a subject, like the 500 pages on ODBS Functions in the MSDN LIbrary, without actually telling you what you need to know.&nbsp;&nbsp;<br><br>Please don't refer me to RDO unless you know where I can get it from as I don't have the Enterprise edition of VB. <br><br>Thanks for helping a frustrated programmer.<br><br>(PS.&nbsp;&nbsp;This is also posted in the Visual Basic forum)<br>
 
I am using a DSN-less connection:
Don't know if this will work for you or not.
In my case the SQL server database is hosted by our ISP thus the &quot;server=WEB_SERVER.com;&quot;

<html>
<%@ Language=VBScript %>
<head>

<title>Brochure Request</title>
</head>

<body>
<%
Set Conn = server.CreateObject(&quot;ADODB.Connection&quot;)
Conn.Open &quot;driver=SQL Server;server=WEB_SERVER.com;uid=USERID;pwd=PASSWORD;database=YOUR_SQL_DATABASE_NAME;&quot;
Set RS = Conn.Execute(&quot;SELECT field_name FROM [tablename]&quot;)

somevalue=RS(&quot;field_name &quot;)

%> [sig]<p>DougP, MCP<br><a href=mailto: dposton@universal1.com> dposton@universal1.com</a><br><a href= > </a><br> Ask me how Bar-codes can help you be more productive.[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top