I'm trying to get Access 2003 to connect to Microsft SQL Server on a
web server.
I can open the linked table without any problem, but whenever I run the
code on my form, it returns this error: Datatyle mismatch in the query
expression.
Heres the Microsfot SQL Server details...
server: mssql.pipeten.c om
username: budgete_kingsga te
password: thehub
database: budgete_kingsga te
And heres the code...
'open recordset
Dim CurrentUserCoun t As Integer
Dim CurrentUser As DAO.Recordset
Set db = CurrentDb
Set CurrentUser = db.OpenRecordse t("SELECT * FROM Users " & _
"WHERE Users.Mobile_No ='" & Cleanest_Mobile & "' AND
Users.PIN='" & txt_PIN & "'; ")
It's simply putting the content of an SQL query into a recordset.
thats not even hard. so can anyone understand why it isn't working?
Cheers
Phil.
web server.
I can open the linked table without any problem, but whenever I run the
code on my form, it returns this error: Datatyle mismatch in the query
expression.
Heres the Microsfot SQL Server details...
server: mssql.pipeten.c om
username: budgete_kingsga te
password: thehub
database: budgete_kingsga te
And heres the code...
'open recordset
Dim CurrentUserCoun t As Integer
Dim CurrentUser As DAO.Recordset
Set db = CurrentDb
Set CurrentUser = db.OpenRecordse t("SELECT * FROM Users " & _
"WHERE Users.Mobile_No ='" & Cleanest_Mobile & "' AND
Users.PIN='" & txt_PIN & "'; ")
It's simply putting the content of an SQL query into a recordset.
thats not even hard. so can anyone understand why it isn't working?
Cheers
Phil.
Comment