M
MikeR
This is a problem on a classic asp page which receives the results from a form submit.
QSOExists is a parameterized query in an Access db.
"SELECT count (*) AS QSOCnt
FROM Worked
WHERE UCall = [In_UCall] and WCall = [In_WCall];"
The fields of interest do exist in the database.
SanCall is set when the page loads, and doesn't change.
The 'In' result is SWCall and SZone respectively
This code snippet gives the results below. It seems one of the Len() calls is failing
for some SWCall/SZone pairs.
SZone = trim(Request.Form("TZone")(i))
SWCall = (UCase(Request.Form("TCall")(i)))
response.write "<br>In " & SWCall & " " & SZone
If (Len(SWCall)) and (Len(SZone)) then
ConnTemp.QSOExists SanCall, SWCall, QRS
response.write "<br> Count: " & QRS("QSOCnt") & " " & SWCall & " " & SZone
In ZD8UW 36
In ZF2NN 8
Count: 1 ZF2NN 8
This snippet gives the expected results. Note the difference in the 'If' statement
SZone = trim(Request.Form("TZone")(i))
SWCall = (UCase(Request.Form("TCall")(i)))
response.write "<br>In " & SWCall & " " & SZone
If (Len(SWCall) > 0) and (Len(SZone) > 0) then
ConnTemp.QSOExists SanCall, SWCall, QRS
response.write "<br> Count: " & QRS("QSOCnt") & " " & SWCall & " " & SZone
In ZD8UW 36
Count: 1 ZD8UW 36
In ZF2NN 8
Count: 1 ZF2NN 8
What am I missing?
Thanks, Mike
QSOExists is a parameterized query in an Access db.
"SELECT count (*) AS QSOCnt
FROM Worked
WHERE UCall = [In_UCall] and WCall = [In_WCall];"
The fields of interest do exist in the database.
SanCall is set when the page loads, and doesn't change.
The 'In' result is SWCall and SZone respectively
This code snippet gives the results below. It seems one of the Len() calls is failing
for some SWCall/SZone pairs.
SZone = trim(Request.Form("TZone")(i))
SWCall = (UCase(Request.Form("TCall")(i)))
response.write "<br>In " & SWCall & " " & SZone
If (Len(SWCall)) and (Len(SZone)) then
ConnTemp.QSOExists SanCall, SWCall, QRS
response.write "<br> Count: " & QRS("QSOCnt") & " " & SWCall & " " & SZone
In ZD8UW 36
In ZF2NN 8
Count: 1 ZF2NN 8
This snippet gives the expected results. Note the difference in the 'If' statement
SZone = trim(Request.Form("TZone")(i))
SWCall = (UCase(Request.Form("TCall")(i)))
response.write "<br>In " & SWCall & " " & SZone
If (Len(SWCall) > 0) and (Len(SZone) > 0) then
ConnTemp.QSOExists SanCall, SWCall, QRS
response.write "<br> Count: " & QRS("QSOCnt") & " " & SWCall & " " & SZone
In ZD8UW 36
Count: 1 ZD8UW 36
In ZF2NN 8
Count: 1 ZF2NN 8
What am I missing?
Thanks, Mike