Jakub Jurdziak
2007-Jan-22 22:16 UTC
[R] [R-pkgs] eval() parse() and problem with square brackets
Hello, i have problem with the following code (I'm using sqlQuery function from RODBC package): eval(parse(text="g_1 <- sqlQuery(cnn_1, \"select aa from bb.[cc\\dd].ee\")")). I get the error message: "[RODBC] ERROR: Could not SQLExecDirect" "S0002 208 [Microsoft][ODBC SQL Server Driver][SQL Server]Invalid object name 'bb.cc\dd.ee'." It seems that R is replacing square brackets that are needed for database to execute query. How can I force R to change its behavior and leave square brackets unchanged? Any ideas appreciated Kuba _______________________________________________ R-packages mailing list R-packages at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-packages
Hello, i have problem with the following code (I'm using sqlQuery function from RODBC package): eval(parse(text="g_1 <- sqlQuery(cnn_1, \"select aa from bb.[cc\\dd].ee\")")). I get the error message: "[RODBC] ERROR: Could not SQLExecDirect" "S0002 208 [Microsoft][ODBC SQL Server Driver][SQL Server]Invalid object name 'bb.cc\dd.ee'." It seems that R is replacing square brackets that are needed for database to execute query. How can I force R to change its behavior and leave square brackets unchanged? Any ideas appreciated. Kuba