powered by
dbEscapeStrings(con, strings, ...)## S3 method for class 'MySQLConnection,character': dbEscapeStrings(con, strings)## S3 method for class 'MySQLResult,character': dbEscapeStrings(con, strings, ...)
## S3 method for class 'MySQLConnection,character': dbEscapeStrings(con, strings)
## S3 method for class 'MySQLResult,character': dbEscapeStrings(con, strings, ...)
dbConnect
if (mysqlHasDefault()) { con <- dbConnect(RMySQL::MySQL(), dbname = "test") tmp <- sprintf("SELECT * FROM emp WHERE lname = %s", "O'Reilly") dbEscapeStrings(con, tmp) dbDisconnect(con) }
Run the code above in your browser using DataLab