Mr. David Summers
New member
I am converting an access mdb to a new MySQL database. from my classic asp website.
and although i can read the data from the SQL i cannot update recordsets. it gives me an error that i do not have update permission. ....oookkk. so since i was able to create the thing, why cant i insert a new record into my table.
searching all over Google i haven't found a single straight answer that makes sense into how to allow permissions to myself to update the MySQL database table. I'm about to tear out my hair. PLEASE SOMEONE HELP ME!
i believe my code is correct:
strDBPath = "Driver={MySQL ODBC 3.51 Driver};SERVER=server;DATABASE=database;UID=username;PWD=pasword;"
Set conn = Server.CreateObject("ADODB.Connection")
conn.Open strDBPath
sql="INSERT INTO pageContent (pageName,revisionDate,"
sql=sql & "revisionTime,pageText,adSpace)"
sql=sql & " VALUES "
sql=sql & "('" & pageName & "',"
sql=sql & "'" & date() & "',"
sql=sql & "'" & time() & "',"
sql=sql & "'" & pageText & "',"
sql=sql & "'" & adSpace & "')"
on error resume next
conn.Execute sql,recaffected
if err<>0 then
Response.Write("No update permissions!")
else
Response.Write("<h3>" & recaffected & " record added</h3>")
end if
conn.close
and the out put is: "No update permissions" and nothing gets updated or put into the database.
oh gawd!
and although i can read the data from the SQL i cannot update recordsets. it gives me an error that i do not have update permission. ....oookkk. so since i was able to create the thing, why cant i insert a new record into my table.
searching all over Google i haven't found a single straight answer that makes sense into how to allow permissions to myself to update the MySQL database table. I'm about to tear out my hair. PLEASE SOMEONE HELP ME!
i believe my code is correct:
strDBPath = "Driver={MySQL ODBC 3.51 Driver};SERVER=server;DATABASE=database;UID=username;PWD=pasword;"
Set conn = Server.CreateObject("ADODB.Connection")
conn.Open strDBPath
sql="INSERT INTO pageContent (pageName,revisionDate,"
sql=sql & "revisionTime,pageText,adSpace)"
sql=sql & " VALUES "
sql=sql & "('" & pageName & "',"
sql=sql & "'" & date() & "',"
sql=sql & "'" & time() & "',"
sql=sql & "'" & pageText & "',"
sql=sql & "'" & adSpace & "')"
on error resume next
conn.Execute sql,recaffected
if err<>0 then
Response.Write("No update permissions!")
else
Response.Write("<h3>" & recaffected & " record added</h3>")
end if
conn.close
and the out put is: "No update permissions" and nothing gets updated or put into the database.
oh gawd!