Home » RDBMS Server » Server Utilities » why sqlloader cann't execute when control filename include character "@"
icon8.gif  why sqlloader cann't execute when control filename include character "@" [message #111061] Sat, 12 March 2005 22:05 Go to next message
zhangjiecsdn
Messages: 2
Registered: March 2005
Junior Member
hi all:
when I execute then command in windows:
sqlldr user/password@SERVERNAME control=c:\mydata@customer.ctl
show errors:
SQL*Loader-500: cann't open file (c:\mydataSERVERNAMEcustomer.ctl)
it changed @ to SERVERNAME automative.

also:
when I write control file such as:
options(errors=1,direct=true)
load data
infile 'd:\mydata@customer.txt'
show errors:
SQL*Loader-500: cann't open file (c:\mydataSERVERNAMEcustomer.txt)

I must use character "@", what can I do?
thanks!
Re: why sqlloader cann't execute when control filename include character "@" [message #111080 is a reply to message #111061] Sun, 13 March 2005 10:51 Go to previous message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
--
-- A little scripting should help.
-- here myscript is the script file is used.
-- it will take two parameters, first a control file_name and then the data file_name.
--
-- It is simple. You can make it any fancy you want
bash-2.03$ myscript  my@member.ctl my@member.dat

SQL*Loader: Release 9.2.0.4.0 - Production on Sun Mar 13 10:41:50 2005

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

Commit point reached - logical record count 5
--
-- this is the script.
--
bash-2.03$ cat myscript
#!/usr/bin/bash
# copy the controlfile and datafile into a simple file, with no specialcharacters file_name.
cp $1 myctl.ctl
cp $2 mytemp.dat
#edit the control and replace your new dat file and use this ctl file to load using sqlldr
#clean all the tempfiles.
sed -e "s/$2/mytemp.dat/g" myctl.ctl > run.ctl
sqlldr userid=mag/mag control=run.ctl
rm myctl.ctl
rm mytemp.dat
rm run.ctl
Previous Topic: Importing data
Next Topic: Importing an 8i dump file into a 9i database
Goto Forum:
  


Current Time: Wed Jul 03 09:22:44 CDT 2024