I have an sql query function below which works if I insert a value for memberID (eg 4528). However it does not work if I insert the variable name memberID. The variable memberID is obtained from the function getData() - see below - and this is functioning correctly.
I do not understand the syntax required to insert the variable memberID into the sql function.
Tks for help
sql = "select T1ytdlatest,T2ytdlatest,T3ytdlatest from registrations WHERE memberID = memberID"
form = cgi.FieldStorage()
memberID = form.getvalue('memberID')