millerfw
asked on
Display value of query result in ASP
Hi Experts,
This seems simple enough but I can't figure it out or find a solution, all I want to do is execute a sql query
sqlNewClients = "SELECT COUNT(AdvisorID) AS NewAdvisorID FROM TFN_Advisors"
And write the result in my ASP page
I need to replace There Are sqlNewClients with the correct syntax. Thanks
This seems simple enough but I can't figure it out or find a solution, all I want to do is execute a sql query
sqlNewClients = "SELECT COUNT(AdvisorID) AS NewAdvisorID FROM TFN_Advisors"
And write the result in my ASP page
I need to replace There Are sqlNewClients with the correct syntax. Thanks
Dim objCmd
Set objCmd = Server.Createobject("ADODB.Connection")
strConnectionString = "Driver={SQL SERVER};Server=XXX.XX.XXX.XXX;Database=NAME;Uid=user;Pwd=password"
objCmd.Open strConnectionString
objCmd.Execute sqlNewClients
Set objCmd = Nothing
Response.Write("NewAdvisorID")
%>
<BR>
<font color ="navy" size=5><b><%="There Are sqlNewClients %>
<BR>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER