J
Junior
Tina and John Vinson - helped me in a prior msg to convert ServiceID from
number to string
I'm trying to use this in a function with the parameter passed from a
control on a report.
Below is the recommended syntax from Tina and John. however, with this SQL -
I get runtime error 3061 - too few parameters, expected 2
strSQL = "SELECT * FROM QrptSum WHERE ServiceID ='" & strSVCID & "'"
debug displays - strSVCID ="05"
From the function
Public Function GetReasons(strSVCID As String)
debug displays - strSVCID ="05"
Set rst = dbs.OpenRecordset(strSQL)
debug highlights this line and displays - SELECT * FROM QrptSum WHERE
ServiceID ='05"'"
this works in query design window but
apparently, i'm not matching ServiceID and strSVCID in SQL
Help please....
number to string
I'm trying to use this in a function with the parameter passed from a
control on a report.
Below is the recommended syntax from Tina and John. however, with this SQL -
I get runtime error 3061 - too few parameters, expected 2
strSQL = "SELECT * FROM QrptSum WHERE ServiceID ='" & strSVCID & "'"
debug displays - strSVCID ="05"
From the function
Public Function GetReasons(strSVCID As String)
debug displays - strSVCID ="05"
Set rst = dbs.OpenRecordset(strSQL)
debug highlights this line and displays - SELECT * FROM QrptSum WHERE
ServiceID ='05"'"
this works in query design window but
apparently, i'm not matching ServiceID and strSVCID in SQL
Help please....