[R] pass a string to a function

Yu-Ling Wu yuling5 at yahoo.com
Tue Feb 13 21:53:35 CET 2001


Hi,

I'd like to pass a string to a function as the value
of the argument.
Here is my code. However, it doesn't work. Please help
me with this.

Thanks,
Yu-Ling Wu
-----------------------------------------------------
library(RODBC)
odbcConnect("console") -> myConnect

fun1 <- function(dd1) {
h3 <- sqlQuery(myConnect, "select * from console where
byday = 'dd1'group by by hour")
}

fun1('010122')
print(summary(h3)

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list