I have a nasty bug. Have worked and researched for hours. The issue is that I keep getting these two errors no matter what I try. In the update sql, if the where clause has a space it gives the 913 error. With no space it gives the 259 error.
& [currdetailid] & " ;"
& [currdetailid] & ";"
The value for currdetailid = 10641
All fields in the update query are integers. Below is all the code. Really could use some help here and anything would be appreciated.
CODE BELOW
Dim currdetailid As Integer
currdetailid = Forms![00200Frm - Test Detail]![Test Detail ID]
'currdetailid = 10641
Set rst = New ADODB.Recordset
Set cnn = CurrentProject.Connection
strSQL = "UPDATE [00200 - TestDetailTbl] SET " & _
" [00200 - TestDetailTbl].[Test Claim ID] = " & [SEQ_CLAIM_ID1] & ", [00200 - TestDetailTbl].[Line ID] = " & [LineID1] & " " & _
" WHERE [00200 - TestDetailTbl].[Test Detail ID] = " & [currdetailid] & " ;"
With rst
.Open strSQL, cnn, adOpenKeyset, adLockBatchOptimistic
End With
& [currdetailid] & " ;"
& [currdetailid] & ";"
The value for currdetailid = 10641
All fields in the update query are integers. Below is all the code. Really could use some help here and anything would be appreciated.
CODE BELOW
Dim currdetailid As Integer
currdetailid = Forms![00200Frm - Test Detail]![Test Detail ID]
'currdetailid = 10641
Set rst = New ADODB.Recordset
Set cnn = CurrentProject.Connection
strSQL = "UPDATE [00200 - TestDetailTbl] SET " & _
" [00200 - TestDetailTbl].[Test Claim ID] = " & [SEQ_CLAIM_ID1] & ", [00200 - TestDetailTbl].[Line ID] = " & [LineID1] & " " & _
" WHERE [00200 - TestDetailTbl].[Test Detail ID] = " & [currdetailid] & " ;"
With rst
.Open strSQL, cnn, adOpenKeyset, adLockBatchOptimistic
End With
Last edited: