Home » RDBMS Server » Server Utilities » Piping STDIN to SQLLDR on Windows (Oracle 10G Windows)
Piping STDIN to SQLLDR on Windows [message #391810] Fri, 13 March 2009 12:24 Go to next message
Rudolphk
Messages: 7
Registered: March 2009
Location: Washington D.C.
Junior Member
I am having trouble replicating functionality I commonly employ on Unix.

In Unix a typical command would be:

gzcat somefile.dat | sqlldr userid=foo/bar control=mycontrol.ctl

and the control file has specified:

INFILE '-'

How do I replicate this in Windows? I keep getting errors like "Unable to open file (-.dat)". I really want to avoid having to work with named pipes.
Re: Piping STDIN to SQLLDR on Windows [message #391814 is a reply to message #391810] Fri, 13 March 2009 12:59 Go to previous messageGo to next message
Michel Cadot
Messages: 68647
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
As far as I lknow, you can't do the same thing in Windows.

Regards
Michel
Re: Piping STDIN to SQLLDR on Windows [message #391815 is a reply to message #391810] Fri, 13 March 2009 13:15 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
***Untested code***
It is been long time I did anything in Windows. Something like this should work

type dept.dat | sqlldr userid=scott/tiger control=somectl.ctl data=\"-\"


Edit:
Tested and worked fine.

/forum/fa/5892/0/
  • Attachment: Picture 1.png
    (Size: 19.10KB, Downloaded 3071 times)

[Updated on: Fri, 13 March 2009 13:31]

Report message to a moderator

Re: Piping STDIN to SQLLDR on Windows [message #391820 is a reply to message #391810] Fri, 13 March 2009 13:56 Go to previous messageGo to next message
Rudolphk
Messages: 7
Registered: March 2009
Location: Washington D.C.
Junior Member
hmmm. I don't know why it doesn't work on my machine. I tried the data=\"-\" at the command line and got the same error.

Windows XP. Oracle SQLLDR 10.2.0.1
Re: Piping STDIN to SQLLDR on Windows [message #391821 is a reply to message #391820] Fri, 13 March 2009 13:58 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
I did not specify infile inside the control file.
Did you?
Re: Piping STDIN to SQLLDR on Windows [message #391822 is a reply to message #391810] Fri, 13 March 2009 14:00 Go to previous messageGo to next message
Rudolphk
Messages: 7
Registered: March 2009
Location: Washington D.C.
Junior Member
Yes, I had removed the INFILE parameter from the control file prior to rerunning my test.
Re: Piping STDIN to SQLLDR on Windows [message #391823 is a reply to message #391822] Fri, 13 March 2009 14:15 Go to previous message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
Bug 4944120
Works upto 10.1.0.4 . No more works for 10.2.0.1 on windows.
Seems you are lucked out!.

[Updated on: Fri, 13 March 2009 14:17]

Report message to a moderator

Previous Topic: Getting EXP-00091, error- ora 04031 while performing export
Next Topic: EXP error
Goto Forum:
  


Current Time: Mon Apr 29 10:56:24 CDT 2024