I just wonder if you know where to find a开发者_如何学C tutorial or samples of a Ruby script using sql *loader?
Sqlldr is a command line utility that uses a control file to guide it.
http://download.oracle.com/docs/cd/B19306_01/server.102/b14215/ldr_concepts.htm#g1013706
An example using system and referencing the loader.ctl control file would be:
system("sqlldr username@server/password control=loader.ctl")
First you have to make sure your configuration (sqlloader commandline switches + controlfile + datafile) works outside Ruby. Then you can call it via system() as previous answer said.
精彩评论