Update Query Running with no errors but no updating (1 Viewer)

josephff

Registered User.
Local time
Today, 12:12
Joined
Oct 25, 2011
Messages
72
I've seen a couple post on this issue but none that solved my issue.

I have update statements that run flawlessy but do not actually update...any help would be appreciated in trying to pin point this out.

I have stepped through the code and all variables are being pulled correctly

just snipped a single statement of the sql statements as they are alll similiar

Code:
Dim sql1 as string        
Dim PONumber1 As String
PONumber1 = Me.BranchTxt.Value & Me.PONumberTxt.Value
 
 sql1 = "UPDATE POMain SET POMain.POSignature = '" & Me.SigTxt.Value & "' WHERE (((POMain.PONumber) = '" & PONumber1 & "'))"
 
        DoCmd.SetWarnings False
        DoCmd.RunSQL sql1
        DoCmd.SetWarnings True
 

vbaInet

AWF VIP
Local time
Today, 18:12
Joined
Jan 22, 2010
Messages
26,374
Why don't you comment out the SetWarnings False line and see what the UPDATE message is.
 

josephff

Registered User.
Local time
Today, 12:12
Joined
Oct 25, 2011
Messages
72
Why don't you comment out the SetWarnings False line and see what the UPDATE message is.

it gave me the "you are about to update 1 record" deal but still didnt update it
 

josephff

Registered User.
Local time
Today, 12:12
Joined
Oct 25, 2011
Messages
72
ugh i figured it out, for some reason if that control has focus it will not update
 

josephff

Registered User.
Local time
Today, 12:12
Joined
Oct 25, 2011
Messages
72
thanks for replying vbaInet, seems like thats everytime i ask a question i figure it out as soon as i post it lol
 

vbaInet

AWF VIP
Local time
Today, 18:12
Joined
Jan 22, 2010
Messages
26,374
It looks like posting a thread helps you recollect your thoughts :) Glad to hear it's resolved!
 

Users who are viewing this thread

Top Bottom