Re: Update an SQL database

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



I did what you told me and both strServerName and
objRecordSet.Fields("server") shows absolutely nothing. I only get blank
message boxes with an ''OK'' button.

"Bob Barrows [MVP]" wrote:

Meat wrote:
Hello Bob,

The vbscrit isn't run by an asp page,
Hmm, I've just taken another look at your code and I'm not sure now what
made me think it was. Sorry

I run it manually on a server
to see if my connection and querie to the SQL database is working
well. That's why I put those WScript.Echo. I watch it live and I
click OK when needed.

The problem I got is with this line :

Insert here:
Wscript.Echo Recordset contains '" & objRecordSet.Fields("Server") & "'"
Wscript.Echo Variable contains '" & strServerName & "'"

**********************************************************
If objRecordSet.Fields("Server") = strServerName Then
**********************************************************

It seems that this line isn't working, because I do not see the
WScript.Echo lines after, even if I know that this condition is true.

Do I need to convert both variables into text or any other kind of
data to be able to compare them?

I will better be able to answer after you have done the above.

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.



.


Quantcast