Computing.Net > Forums > Database > field not updating

field not updating

Reply to Message Icon

Original Message
Name: hc54
Date: June 8, 2007 at 12:33:52 Pacific
Subject: field not updating
OS: xp
CPU/Ram: 512
Model/Manufacturer: ibm
Comment:

I am updating two fields in a sql server DB from a VB6 application. field2 updates fine but field1 is not updating at all. I tried the query in analyzer and it worked fine there but is not working in the code. Here is the vb code:
sSQL = " UPDATE " & tablename
sSQL = sSQL & " SET field1 = ' ', "
sSQL = sSQL & " field2 = 'N'"
sSQL = sSQL & " WHERE RTRIM(field3) = " & variable1

Like I said, it works fine in query analyzer and I have arranged the order, tried setting it to null, gave it a actual value and nothing works.


Report Offensive Message For Removal


Response Number 1
Name: hc54
Date: June 8, 2007 at 13:03:27 Pacific
Reply: (edit)

never mind. I solved it.


Report Offensive Follow Up For Removal







Use following form to reply to current message:

   Name: From My Computing.Net Settings
 E-Mail: From My Computing.Net Settings

Subject: field not updating

Comments:

 


  Homepage URL (*): 
Homepage Title (*): 
         Image URL: 
 
Data Recovery Software




Have you ever used OpenOffice?

Yes, as my main suite.
Yes, occationally.
Yes, but only once.
No, never.


View Results

Poll Finishes In 6 Days.
Discuss in The Lounge