[R] Implementing R through Oracle

Don MacQueen macq at llnl.gov
Fri Nov 9 01:36:06 CET 2007


If it were me, I think I would try to use Rscript. R will still have 
to pull data using ROracle, and write back to Oracle, but the 
operation will be under the control of the pl/sql script.

A standard R installation now includes Rscript. Rscript is intended 
to be used, as I recall, in a manner analogous to perl or any other 
typical scripting language. That is, create a file whose first line is

   #!/path/to/Rscript

and that contains R code, including the use of ROracle. That script, 
if marked executable, can be executed from the command line. So if 
pl/sql can execute any arbitrary script file, then you can execute R 
from within a pl/sql script.

I'm describing a unix (Linux, Mac OS) type environment. Windows is 
foreign territory to me.

-Don

At 12:41 PM -0800 11/5/07, jah wrote:
>I have looked through all the ROracle documentation, R-help, R-dev, Googled
>the world and still cannot figure out this issue. Everything I read it is
>about connecting to an Oracle database and pulling data, processing it, and
>then pushing it back to Oracle. I am running in pl/sql code so I already
>have a Oracle session open. What I want to do is from Oracle call R. I am
>having a mental challenge in seeing how this can be done. Any words of
>wisdon?
>--
>View this message in context: 
>http://www.nabble.com/Implementing-R-through-Oracle-tf4719929.html#a13595057
>Sent from the R help mailing list archive at Nabble.com.
>
>______________________________________________
>R-help at r-project.org mailing list
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
>and provide commented, minimal, self-contained, reproducible code.


-- 
--------------------------------------
Don MacQueen
Environmental Protection Department
Lawrence Livermore National Laboratory
Livermore, CA, USA
925-423-1062



More information about the R-help mailing list