I'm new to SQL. I have a page that is requesing an memberID from another page. It takes it inserts it into a table and displays the members info. it used to be a number, but i am switching it to text and it's not working. The database record has been set to text. I would really appreciate any help. thanks,
the error is with this line...
RS.Open "SELECT * FROM Members WHERE memberID=" & "member_ID"
--------------------------------here's the code-----
<%
' Get the Member ID
member_ID = Request( "mid" )
' Open the Database Connection
Set Con = Server.CreateObject( "ADODB.Connection" )
Con.Open "jobs"
' Open the Recordset
Set RS = Server.CreateObject( "ADODB.Recordset" )
RS.ActiveConnection = Con
RS.CursorType = 3
RS.Open "SELECT * FROM Members WHERE memberID=" & "member_ID"
IF NOT RS.EOF THEN
first_Name = RS( "firstName" )
last_Name = RS( "lastName" )
email_mem = RS( "email" )
phone_mem = RS( "phone" )
address_mem = RS( "address" )
city_mem = RS( "city" )
state_mem = RS( "state" )
zipMem = RS( "zip" )
END IF
' Close the Recordset
RS.Close
the error is with this line...
RS.Open "SELECT * FROM Members WHERE memberID=" & "member_ID"
--------------------------------here's the code-----
<%
' Get the Member ID
member_ID = Request( "mid" )
' Open the Database Connection
Set Con = Server.CreateObject( "ADODB.Connection" )
Con.Open "jobs"
' Open the Recordset
Set RS = Server.CreateObject( "ADODB.Recordset" )
RS.ActiveConnection = Con
RS.CursorType = 3
RS.Open "SELECT * FROM Members WHERE memberID=" & "member_ID"
IF NOT RS.EOF THEN
first_Name = RS( "firstName" )
last_Name = RS( "lastName" )
email_mem = RS( "email" )
phone_mem = RS( "phone" )
address_mem = RS( "address" )
city_mem = RS( "city" )
state_mem = RS( "state" )
zipMem = RS( "zip" )
END IF
' Close the Recordset
RS.Close