Dim strSQL
'Verify user information in the database
strSQL = "SELECT membername, memberemail, memberpassword FROM memberinfo WHERE &_
membername = CStr(Request.Form("txtFirstName")) & _
memberemail = CStr(Request.Form("txtEmail")) & _
memberpassword = CStr(Request.Form("txtPassword"));"
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open "DSN=conhcn"
Set objCmd = Server.CreateObject("ADODB.Command")
Set objCmd.ActiveConnection = objConn
objCmd.CommandText = strSQL
objCmd.CommandType = adCmdText
'Check for database errors
Call CheckForErrors(objConn)
I'm tring to verify users login info from a form to my access database, i tried using stored procedures but it wasn't working for me.. i'm reading the wrox "beginning asp databases" (not .net):)
anyway,,, i'm a little confused on syntax with the
vb and sql..
below is what i tried.. and it didn't work:(
any help would be great!
thanks
'Check for empty recordset which indicates user information
'was not found
If objRS.EOF or objRS.BOF Then
Session("ErrorMessage") = "No record found - Please ensure all information was entered correctly"
Response.Redirect "Default.asp"
Else
Session("ErrorMessage") = Empty
Response.Redirect "member.asp"
End If
%>