Sqlldr on Oracle 8.1.6
on RedHat 6.1
Segmentation fault (core dumped)
whenever I run sqlldr
Do you still have to run 8.1.5 patch?
null
on RedHat 6.1
Segmentation fault (core dumped)
whenever I run sqlldr
Do you still have to run 8.1.5 patch?
null
Similar Messages
-
Error in Loading Data with SQLLDR in Oracle 10G
Hello,
Can any one suggest whats the problem in the below mentioned Control file used for loading data through SQL*LOADER
LOAD DATA
INFILE 'D:\test\temt.txt'
BADFILE 'test.bad'
DISCARDFILE 'test.dsc'
INTO TABLE "TEST"
INSERT
(SRNO INTEGER(7),
PROD_ID INTEGER(10),
PROMO_ID INTEGER(10),
CHANNEL_ID INTEGER(10),
UNIT_COST INTEGER(10),
UNIT_PRICE INTEGER(10)
I am trying to load data in SCOTT schema as user scott.
Why do i get such an error, please refer the attach Log file.
SQL*Loader: Release 10.2.0.1.0 - Production on Fri Mar 20 14:43:35 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Control File: D:\test\temt.ctl
Data File: D:\test\temt.txt
Bad File: test.bad
Discard File: test.dsc
(Allow all discards)
Number to load: ALL
Number to skip: 0
Errors allowed: 50
Bind array: 64 rows, maximum of 256000 bytes
Continuation: none specified
Path used: Conventional
Table "TEST", loaded from every logical record.
Insert option in effect for this table: INSERT
Column Name Position Len Term Encl Datatype
SRNO FIRST 7 INTEGER
PROD_ID NEXT 10 INTEGER
PROMO_ID NEXT 10 INTEGER
CHANNEL_ID NEXT 10 INTEGER
UNIT_COST NEXT 10 INTEGER
UNIT_PRICE NEXT 10 INTEGER
Record 1: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 2: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 3: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 4: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 5: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 6: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 7: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 8: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 9: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 10: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 11: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 12: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 13: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 14: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 15: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 16: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 17: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 18: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 19: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 20: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 21: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 22: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 23: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 24: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 25: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 26: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 27: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 28: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 29: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 30: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 31: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 32: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 33: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 34: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 35: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 36: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 37: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 38: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 39: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 40: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 41: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 42: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 43: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 44: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 45: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 46: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 47: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 48: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 49: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 50: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
Record 51: Rejected - Error on table "TEST".
ORA-01460: unimplemented or unreasonable conversion requested
MAXIMUM ERROR COUNT EXCEEDED - Above statistics reflect partial run.
Table "TEST":
0 Rows successfully loaded.
51 Rows not loaded due to data errors.
0 Rows not loaded because all WHEN clauses were failed.
0 Rows not loaded because all fields were null.
Space allocated for bind array: 3648 bytes(64 rows)
Read buffer bytes: 1048576
Total logical records skipped: 0
Total logical records read: 64
Total logical records rejected: 51
Total logical records discarded: 0
Run began on Fri Mar 20 14:43:35 2009
Run ended on Fri Mar 20 14:43:43 2009
Elapsed time was: 00:00:07.98
CPU time was: 00:00:00.28
Below is the method of using SQLLDR and table details,
SQL> desc test
Name Null? Type
SRNO NUMBER(7)
PROD_ID NUMBER(10)
PROMO_ID NUMBER(10)
CHANNEL_ID NUMBER(10)
UNIT_COST NUMBER(10)
UNIT_PRICE NUMBER(10)
Method for using sqlldr is :
cmd promt,
d:\> sqlldr scott/tiger
control = D:\test\temt.ctl
SQL*Loader: Release 10.2.0.1.0 - Production on Fri Mar 20 15:55:50 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Commit point reached - logical record count 64
I even tried few examples,
Which of the below mentioned Control file make sense,
--1
LOAD DATA
INFILE 'D:\test\temt.txt'
BADFILE 'test.bad'
DISCARDFILE 'test.dsc'
INTO TABLE "TEST"
INSERT
FIELD TERMINATED BY (,)
(SRNO INTEGER(7),
PROD_ID INTEGER(10),
PROMO_ID INTEGER(10),
CHANNEL_ID INTEGER(10),
UNIT_COST INTEGER(10),
UNIT_PRICE INTEGER(10)
--2
LOAD DATA
INFILE 'D:\test\temt.txt'
BADFILE 'test.bad'
DISCARDFILE 'test.dsc'
INTO TABLE "TEST"
INSERT
FIELD TERMINATED BY (,) optionally enclosed by '"'
(SRNO INTEGER(7),
PROD_ID INTEGER(10),
PROMO_ID INTEGER(10),
CHANNEL_ID INTEGER(10),
UNIT_COST INTEGER(10),
UNIT_PRICE INTEGER(10)
*For code--1 i get below mentioned error..*
D:\>sqlldr scott/tiger
control = D:\test\temt.ctl
SQL*Loader: Release 10.2.0.1.0 - Production on Fri Mar 20 16:36:00 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
SQL*Loader-350: Syntax error at line 8.
Expecting "(", found "FIELD".
FIELD TERMINATED BY (,)
^
*And for code--2 i get the below error,*
D:\>sqlldr scott/tiger
control = D:\test\temt.ctl
SQL*Loader: Release 10.2.0.1.0 - Production on Fri Mar 20 16:39:22 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
SQL*Loader-350: Syntax error at line 8.
Expecting "(", found "FIELD".
FIELD TERMINATED BY (,) optionally enclosed by '"'
^
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------below is the data i am trying to load through sqlldr
1,14,999,3,89098,111287
2,14,999,2,88645,110899
3,14,999,2,90418,117623
4,14,999,3,89272,115999
5,14,999,4,86364,117623
6,15,999,3,87522,101399
7,15,999,4,84671,99999
8,15,999,4,84671,99999
9,15,999,4,86364,101399
10,15,999,4,88735,100399
11,15,999,2,90418,101399
12,15,999,3,89272,101399
13,15,999,2,90418,101399
14,17,999,2,9694,155099
15,17,999,3,97618,155099
16,17,999,3,97618,155099
17,18,999,3,11333,169783
18,18,999,2,11479,163279
19,18,999,3,11333,163279
20,18,999,3,115141,173504
21,18,999,2,117086,165565
22,18,999,2,116856,17532
23,18,999,2,117086,169783
24,19,999,4,489,6237
25,19,999,3,4968,6302
26,20,999,2,52876,60839
27,20,999,3,52202,59999
28,20,999,3,53246,59999
29,20,999,3,54205,60209
30,20,999,3,54205,60209
31,21,999,4,76204,106773
32,21,999,4,76204,106773
33,21,999,3,7877,105299
34,21,999,4,76204,106773
35,21,999,4,77576,105668
36,21,999,3,7877,105299
37,21,999,4,76204,105299
38,21,999,2,81377,107595
39,21,999,2,81377,107595
40,21,999,4,77728,107595
41,22,999,3,2187,2656
42,22,999,2,2216,2661
43,22,999,3,2187,2656
44,22,999,2,2251,2632
45,22,999,3,2187,2656
46,22,999,4,2154,2628
47,22,999,3,2187,2656
48,22,999,3,2231,2661
49,22,999,3,2231,2624
50,22,999,2,2296,2632
51,22,999,3,2231,2661
52,22,999,4,2158,2661
53,23,999,3,1913,2408
54,23,999,3,1951,2375
55,23,999,3,1987,2383
56,23,999,3,1951,2408
57,24,999,4,3946,4943
58,24,999,3,4073,4883
59,24,999,2,4053,4934
60,24,999,2,4053,4866
61,24,999,4,3946,4943
62,24,999,3,4001,4943
63,24,999,3,4154,4892
64,24,999,4,4025,4875
65,24,999,4,4025,4875
66,24,999,2,4134,4875
67,24,999,3,4081,4943
68,24,999,2,4134,4934
69,24,999,4,4025,4943
70,24,999,4,4025,4875
71,24,999,3,4081,4943
72,25,999,3,983,12655
73,25,999,3,983,12655
74,25,999,2,9958,12655
75,25,999,3,983,12655
76,25,999,2,9958,12832
77,25,999,3,10027,12832
78,25,999,2,10157,12774
79,25,999,4,9888,12655
80,25,999,2,10157,12832
81,25,999,4,9888,12832
82,25,999,4,9888,12832
83,26,999,3,1305,17034
84,26,999,3,1305,16799
85,26,999,3,13551,16858
86,27,999,3,3992,4927
87,27,999,3,4064,4876
88,29,999,3,43761,56175
89,29,999,2,44942,55621
90,29,999,4,42335,55399
91,29,999,2,44322,55399
92,29,999,2,45208,56175
93,29,999,2,45208,56175
94,29,999,4,43182,56175
95,29,999,3,44636,56175
96,29,999,4,43182,56175
97,29,999,4,43182,56175
98,30,999,3,869,1094
99,30,999,4,857,1079
100,30,999,2,898,1079
---------------------------------------------------------------------------------------------------------------------------------------------------------------------- -
SQLLDR: Setting oracle apps context before calling sqlldr
Hi,
I am on oracle apps 11.5.10. We are calling FND apis like fnd_global.user_id within control file to get current user etc.. SQLLDR is called from host based concuurent program(shell script). Since context is not set in host program when we call plsql packages so FND apis global value returns -1.
Is there a way we can set the context or make FND APIS return value as if we are calling from PLSQL concurrent program.
Thanks much.not that i'm aware of. Maybe you can use external table(s) instead?
-
Error loading xml file with sqlldr
Hi there,
I am having trouble loading an xml file via sqlldr into oracle.
The version i am running is Oracle Database 10g Release 10.2.0.1.0 - 64bit Production and the file size is 464 MB.
It ran for about 10 hours trying to load the file and then threw up the error:
ORA-22813: operand value exceeds system limits.
I have loaded a file of 170MB using the same process succesfully.
Any Ideas?
Cheers,
Dan.Looked a bit into the issue (ORA-22813) and although it can be caused by a lot of issues varrying database versions, you could have a go at sizing up your PGA database parameter. See Oracle support Doc ID 837220.1 for more info.
The following might help
CREATE OR REPLACE PROCEDURE show_pga_memory (context_in IN VARCHAR2 DEFAULT NULL)
SELECT privileges required on:
SYS.v_$session
SYS.v_$sesstat
SYS.v_$statname
Here are the statements you should run:
GRANT SELECT ON SYS.v_$session TO <schema>;
GRANT SELECT ON SYS.v_$sesstat TO <schema>;
GRANT SELECT ON SYS.v_$statname TO <schema>;
IS
l_memory NUMBER;
BEGIN
SELECT st.VALUE
INTO l_memory
FROM SYS.v_$session se, SYS.v_$sesstat st, SYS.v_$statname nm
WHERE se.audsid = USERENV ('SESSIONID')
AND st.statistic# = nm.statistic#
AND se.SID = st.SID
AND nm.NAME = 'session pga memory';
DBMS_OUTPUT.put_line (CASE WHEN context_in IS NULL
THEN NULL
ELSE context_in || ' - '
END
|| 'PGA memory used in session = ' || TO_CHAR (l_memory));
END show_pga_memory;
/ -
I want to convert date from Microsoft Access to Oracle.
I want to convert date from Microsoft Access to Oracle.
My Oracel date format is 21-Jul-2004 02:24:09 AM
I use sqlldr in Oracle 9i Database and I
write control file
load data
infile 'test.txt'
into table test
fields terminated by "," optionally enclosed by '"'
trailing nullcols
name,
birthday
data file 'test.txt' for input
"dao","21-Jul-2004 02:24:09 AM"
why did error? ORA-01843: not a valid month
Thank.replace birthday with
birthday "to_date(:birthday, 'DD-Mon-YYYY HH:MI:SS AM', 'NLS_LANGUAGE=''american''')"Of course, if your monthes are in German, then set the language to german (JUL=JUL but DEZ<>DEC)
Regards
Laurent -
UNICODE data files with SQLLDR
how can i load UNICODE data files with SQLLDR.
my Oracle instance is on UNIX with NLS_CHARACTERSET WE8ISO8859P1.
I have .dat files extracted from SQL Server using bcp utility with -w option.
When i use -c option i'm not getting the european characters correctly like the a and e with 2 dots on top....
when i load UNICODE (-w) file with CHARACTERSET UTF8 in my control file, it doesnt go thru. Any solution for this ? Thanks !I just created a unicode textfile on windows with some westeuropean characters and imported it into we8iso8859p1 database on linux using controlfile parameter CHARACTERSET UTF16.
They got all properly converted.
As Justin mentioned, unicode on windows means generally UTF16 Little Endian.
Best regards
Maxim -
I'm running Oracle Server 8.1.6 under Windows2000.
I have two clients : A Oracle Client 8.1.6 and a Oracle Client 8.0.5
I have created a user MyUser.
I have created a table MyTable (into MyUser).
I have created a view MyView (This view is "select * from MyTable").
I have a ctl file that load data into the view.
When i run sqlldr (with userid=MyUser/MyPassword) on the Client 8.1.6, i have the following messages :
SQL*Loader-941: Error during describe of table MyView
ORA-04043: object MyView does not exist
When i run the same thing under Oracle 8.0.5 (with sqlldr80), it works fine.
If i run sqlldr under Oracle 8.1.6 with a ctl file that load data directly into the table MyTable, it works fine.
So I think that we can't use sqlloader with views anymore under Oracle 8i...
Can you help me ?
Thanks.There is a bug in 8.1.6. loading thru views in both conventional and direct path of sql loader.
8.1.6.1 fixes the conventional path bug, but you need to go to 8.1.7 for the direct path fix.
Bob -
We recently switched from Oracle 7.3.4 to Oracle 8.1.7. The input to a sqlldr has duplicate records which causes unique constraint errors. That's not a problem.
The table updates are going fine on the new machine. I'm just curious as to why the script that was used to execute the sqlldr on Oracle 7.3.4 returned a 0 (zero) return code when there were unique contraint warnings, and the identical script and sqlldr code is returning a 2 return code on 8.1.7.
I'm concerned that the non-zero return code may be pointing to something other than the unique constraint issue, that we're not seeing.
The only discernable difference in the log file between the 7.3.4 version and the 8.1.7 version is the following:
Space allocated for bind array: 2560 bytes(64 rows) (old machine)
Space allocated for memory besides bind array: 55256 bytes
Space allocated for bind array: 2560 bytes(64 rows) (new machine)
Space allocated for memory besides bind array: 0 bytes
Does the above "Space allocated" statement mean anything?
SQLLDR Code:
OPTIONS (SILENT=(FEEDBACK))
LOAD DATA
INFILE 'IOR_out.csv'
APPEND
INTO TABLE sap_so_mstr
div_ln position(1:4) CHAR,
acct_so_iwo_ln position(7:16) CHAR,
rec_type position(42:43) CHAR,
SAP_CHG_NBR position(46:53) CHAR,
task_ln constant '0000000'
Sample input to SQLLDR (in real life these values are lined up in columns):
27 , 009911AAAA, 19991126, 20991231, C, IO, 9911AAAA
27 , 009912AAAA, 19991126, 20991231, C, IO, 9912AAAA
27 , 0099H2HRCM, 19991126, 20991231, C, IO, 99H2HRCM
Code within the script calling above SQLLDR code:
sqlldr userid=${DB_USER}/${DB_PASSWORD}, control=${ctlfile} errors=100000
Any ideas? Thanks.Also you can add this in CustomSettings.ini (is located in \\<SERVER>\DeploymentShare$\Control):
;Logging
SLShare=\\<SERVER>\DeploymentShare$\Logs
SLShareDynamicLogging =\\<SERVER>\DeploymentShare$\Logs\%ComputerName%
and in appropriate %ComputerName% folder on <SERVER> during OSD will be generated dinamically updated BDD.log. After OSD is finished rest logs will appear in that folder.
You can inspect this with trace32 from System
Center Configuration Manager 2007 Toolkit V2. -
Error while executing an interface
Hi, I am getting this error:
STEP is :Loading - Srcset0 - Call sqldr
org.apache.bsf.BSFException: exception from Jython:
Traceback (innermost last):
File "<string>", line 31, in ?
File "C:\App\DataIntegrator11g\oracledi\client\odi\bin\..\..\jdev\extensions\oracle.odi.navigator\scripting\Lib\javaos.py", line 198, in system
File "C:\App\DataIntegrator11g\oracledi\client\odi\bin\..\..\jdev\extensions\oracle.odi.navigator\scripting\Lib\javaos.py", line 224, in execute
OSError: (0, 'Failed to execute command ([\'sh\', \'-c\', \'sqlldr stage/oracle control="C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.ctl" log="C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.log" > "C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.out" \']): java.io.IOException: Cannot run program "sh": CreateProcess error=2, The system cannot find the file specified')
at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:146)
at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.execInBSFEngine(SnpScriptingInterpretor.java:345)
at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.exec(SnpScriptingInterpretor.java:169)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java:2374)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execScriptingOrders(SnpSessTaskSql.java:1615)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execScriptingOrders(SnpSessTaskSql.java:1580)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java:2755)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2515)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:534)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:449)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:1954)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:322)
at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:224)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:246)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:237)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:794)
at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:114)
at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:82)
at java.lang.Thread.run(Thread.java:662)
the code is:
import java.lang.String
import java.lang.Runtime as Runtime
from jarray import array
import java.io.File
import os
import re
import javaos
def reportnbrows():
f = open(r"C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.log", 'r')
try:
for line in f.readlines():
if line.find("MAXIMUM ERROR COUNT EXCEEDED")>=0 :
raise line
finally:
f.close()
ctlfile = r"""C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.ctl"""
logfile = r"""C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.log"""
outfile = r"""C:/Proyectos/Dropbox/DatosPrueba/BOGSALD.out"""
oracle_sid=''
if len('')>0: oracle_sid = '@'+''
loadcmd = r"""sqlldr stage/<@=snpRef.getInfo("DEST_PASS") @>%s control="%s" log="%s" > "%s" """ % (oracle_sid,ctlfile, logfile, outfile)
rc = os.system(loadcmd)
if rc <> 0 and rc <> 2:
raise "Load Error", "See %s for details" % logfile
if rc==2:
reportnbrows()Hi,
What is the .log is showing.
The error shows that The system cannot find the file specified. Please check whether the path is correct. And If the path is in differenet server make sure that the folder is shared.
Hope this might give a solution.
Reg
Dhamu -
Error when trying to execute ODI Interface
Hello,
I receive the following error when I try to execute an ODI interface. The interface contains two models trying to load a .csv file into an Oracle table. The models seem to be working and I can right click on the source file and "View Data". I have specifed LKM File To Oracle (SQLLDR), IKM Oracle Incremental Update, and CKM Oracle. But still receive this error on the fourth step of the execution "Loading - SS_0 - call sqlldr via Jython"
org.apache.bsf.BSFException: exception from Jython: Traceback (innermost last):
File "<string>", line 3, in ?
OS command has signalled errors
at org.apache.bsf.engines.jython.JythonEngine.exec(Unknown Source)
at com.sunopsis.dwg.codeinterpretor.k.a(k.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execScriptingOrders(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execScriptingOrders(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlC.treatTaskTrt(SnpSessTaskSqlC.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java)
at com.sunopsis.dwg.cmd.DwgCommandSession.treatCommand(DwgCommandSession.java)
at com.sunopsis.dwg.cmd.DwgCommandBase.execute(DwgCommandBase.java)
at com.sunopsis.dwg.cmd.e.i(e.java)
at com.sunopsis.dwg.cmd.g.y(g.java)
at com.sunopsis.dwg.cmd.e.run(e.java)
at java.lang.Thread.run(Unknown Source)
Thank you for your helpAlmost...
You need the sql loader where the "OS command" will execute it means where the agent is installed (once you will execute it from an agent when at production).
AND that machine where the agent is, need to "see" the target database through the Oracle Listener (tnsnames)....
Is just like to execute a Sql Loader from you own machine, but who write the command will be ODI.
Does it make any sense to you?
Message was edited by:
Cezar Santos -
Using prepareStatement with parameter in existsNode() function
Hello,
I have an xml file like the following:
<MyDocRoot id="myId" xmlns="..." xmlns:xsi="..." xsi:schemaLocation="...">
</MyDocRoot>
I am retrieving my documents from an XMLType table with aquery like:
SELECT OBJECT_VALUE FROM MY_TABLE
WHERE existsNode(OBJECT_VALUE, '/MyDocRoot[@id="myId"]') = 1;
When I run it using oracle client everything works fine and great.
Now I would like to execute that query from a Java application, using prepared statement, so with a query now like:
SELECT OBJECT_VALUE FROM MY_TABLE
WHERE existsNode(OBJECT_VALUE, '/MyDocRoot[@id="?"]') = 1;
And passing the id value as the parameter at execution time.
The problem I am facing is that it seems that the prepare statement does not recognize the parameter at that place. I get an error specifying that one parameter was provided but none was expected.
I get the same problem when I try to update a document in the database. In this case I have the query is:
UPDATE MY_TABLE SET OBJECT_VALUE = XMLType(?)
WHERE existsNode(OBJECT_VALUE, '/MyDocRoot[@id="?"]') = 1
The error I receive specify that 2 parameters were provided but only one was expected (the parameter in the XMLType() is recognized but not the one in the XPATH expression)
Does anybody have an example on how to use prepare statement with parameters in XPATH expression like above?Try this
package com.oracle.st.xmldb.pm.examples;
import com.oracle.st.xmldb.pm.common.baseApp.BaseApplication;
import oracle.jdbc.OraclePreparedStatement;
import oracle.jdbc.OracleResultSet;
import oracle.xdb.XMLType;
import oracle.xml.parser.v2.XMLDocument;
public class GetXMLType extends BaseApplication
public void doSomething(String[] Args) throws Exception
OraclePreparedStatement statement = null;
String statementText;
statementText = "select object_value from PURCHASEORDER where existsNode(object_value,'/PurchaseOrder[Reference=\"' || :1 || '\"]') = 1";
OracleResultSet resultSet = null;
XMLDocument doc = null;
XMLType xml;
statement = (OraclePreparedStatement) getConnection().prepareStatement(statementText);
statement.setString(1,"AHUNOLD-20040817185414366GMT");
resultSet = (OracleResultSet) statement.executeQuery();
while (resultSet.next())
xml = (XMLType) resultSet.getObject(1);
doc = (XMLDocument) xml.getDocument();
doc.print(System.out);
resultSet.close();
statement.close();
getConnection().close();
public static void main (String[] args)
try
GetXMLType example = new GetXMLType();
example.initializeConnection();
example.doSomething(args);
catch (Exception e)
e.printStackTrace();
}Gives
C:\TEMP>
C:\oracle\product\11.1.0\db_1\jdk\bin\javaw.exe -client -classpath C:\xdb\JDeveloper\Classes;C:\oracle\product\11.1.0\db_1\jdbc\lib\ojdbc5.jar;C:\oracle\product\11.1.0\db_1\LIB\xmlparserv2.jar;C:\oracle\product\11.1.0\db_1\RDBMS\jlib\xdb.jar;C:\oracle\JDeveloper\j2ee\home\oc4j.jar;C:\oracle\JDeveloper\j2ee\home\lib\servlet.jar -Dcom.oracle.st.xmldb.pm.ConnectionParameters=C:\\xdb\\jdeveloper\\SimpleExamples\\LocalConnection.xml -Dhttp.proxyHost=www-proxy.us.oracle.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts=localhost|us.oracle.com|*.oracle.com -Dhttps.proxyHost=www-proxy.us.oracle.com -Dhttps.proxyPort=80 -Dhttps.nonProxyHosts=localhost|us.oracle.com|*.oracle.com com.oracle.st.xmldb.pm.examples.GetXMLType -mx2048M
Using connection Parameters from : C:\\xdb\\jdeveloper\\SimpleExamples\\LocalConnection.xml
ConnectionProvider.establishConnection(): Connecting as SQLLDR/SQLLDR@jdbc:oracle:oci8:@(description=(address=(host=localhost)(protocol=tcp)(port=1521))(connect_data=(service_name=ORA11GR1.xp.mark.drake.oracle.com)(server=DEDICATED)))
ConnectionProvider.establishConnection(): Database Connection Established
<PurchaseOrder xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://localhost:8080/home/SCOTT/poSource/xsd/purchaseOrder.xsd">
<Reference>AHUNOLD-20040817185414366GMT</Reference>
<Actions>
<Action>
<User>AHUNOLD</User>
</Action>
</Actions>
<Reject/>
<Requestor>Alexander Hunold</Requestor>
<User>AHUNOLD</User>
<CostCenter>A60</CostCenter>
<ShippingInstructions>
<name>Elizabeth Bates</name>
<address>Magdalen Centre, The Oxford Science Park,
Oxford,
Oxford OX9 9ZB
United Kingdom</address>
<telephone>980-985-4081</telephone>
</ShippingInstructions>
<SpecialInstructions>Next Day Air</SpecialInstructions>
<LineItems>
<LineItem ItemNumber="1">
<Description>Farewell, My Concubine</Description>
<Part Id="717951002723" UnitPrice="19.99" Quantity="3"/>
</LineItem>
<LineItem ItemNumber="2">
<Description>Willy Wonka and the Chocolate Factory</Description>
<Part Id="85392229123" UnitPrice="19.99" Quantity="4"/>
</LineItem>
<LineItem ItemNumber="3">
<Description>Best In Show</Description>
<Part Id="85391895121" UnitPrice="19.99" Quantity="3"/>
</LineItem>
<LineItem ItemNumber="4">
<Description>The Reggae Movie</Description>
<Part Id="13023004597" UnitPrice="19.99" Quantity="1"/>
</LineItem>
</LineItems>
</PurchaseOrder>
Process exited with exit code 0. -
Sql*loader and nested tables
I'm having trouble loading a nested table via sqlldr in Oracle 10g and was hoping someone could point me in the right direction. I keep getting the following error:
SQL*Loader-403: Referenced column not present in table mynamespace.mytable
Here's an overview of my type and table definitions:
create type mynamespace.myinfo as object
i_name varchar2(64),
i_desc varchar2(255)
create TYPE mynamespace.myinfotbl as TABLE of mynamespace.myinfo;
create table mynamespace.mytable
Info mynamespace.myinfotbl,
note varchar2(255)
NESTED TABLE Info STORE AS mytable_nested_tab;
My control file looks like this:
load data
infile 'mydatafile.csv'
insert into table mynamespace.mytable
fields terminated by ',' optionally enclosed by '"'
TRAILING NULLCOLS
Info nested table count(6)
Info column object
i_name char(64),
i_desc char(255)
note
Example mydatafile.csv would be something like:
lvl1,des1,lvl2,des2,lvl3,des3,lvl4,des4,lvl5,des5,lvl6,des6,a test data set
I can't figure out why sqlldr keeps rejecting this control file. I'm using 'direct=false' in my .par file.
Any hints?I just noticed that my email is wrong. If you can help, plese send email to [email protected]
thanks. -
How are you handling ASCII 0 values
Hi,
I have noticed a strange thing with ASCII 0 values. in the process of database replication MSSQL to Oracle some columns in the source DB (MSSQL) have some of the values as ascii 0.
when i load this data with sqlldr in oracle and query the table this columns are not considered as null.
ex:
table_name : PriceItems
Column_name : Description
if i query the table with select count() from PriceItems where Description is null* the result is 0
if i query the table with select count() from PriceItems where Description = chr(0)* the result is 301 (actual rows)
how can we handle this kind of situations?
is this a bug of Oracle?
My Oracle Version:
Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
PL/SQL Release 11.1.0.7.0 - Production
"CORE 11.1.0.7.0 Production"
TNS for Linux: Version 11.1.0.7.0 - Production
NLSRTL Version 11.1.0.7.0 - Production
Edited by: user8999602 on Sep 3, 2012 9:22 AMAscii character zero indicates a NULL character. Not a null string.
A null string is a string without a value - i.e. a string that has no ASCII (or EBCDIC or Unicode) characters. Oracle does not discriminate between Ascii characters.
Character zero is used, on Windows for example, as string terminator. An empty string can thus only contain a zero terminator. And thus the confusion. An empty string is not the same as a null string in this case - but a zero string length implies the string is empty, does not contain characters (despite containing a char zero), and is therefore null.
The issue is inconsistencies in implementation and terminology. NULL itself is a very abused concept in software engineering. -
SQL LOADER and ORA-01861: literal does not match format string
Hi,
I've to load data through control_file(.ctl) into oracle table through sqlldr. Oracle 11g, win xp.
as soon as I use - sqlldr dss/dss control=orders.ctl I get error or nothing.
Text file that is generated after loading fails has the following error.
Record 1: Rejected - Error on table ORDERS, column O_ORDERDATE.
ORA-01861: literal does not match format string
I have checked the format of data to be loaded into Orders table is like this : *1996-01-02.*
I checked the format of data in my database by querying sysdate from dual i.e. 10-JAN-10
I thought that changing its format might solve my problem so i tried this:
SQL> alter session set nls_date_format='YYYY-MM-DD';
Session altered.
SQL> select sysdate from dual;
SYSDATE
2010-01-10but still i'm getting the same error. I've to load millions of data. how I can solve this issue.
Please suggest.
Thanks alot.
Best Regads,
KamHi,
It's strange ....nobody knew it?. I think this type of load problem will be very common isn't it.... where date column data is in a different format than in the db i.e.
How to change *1996-01-02* in the Control_file to make it able to load in the table where sysdate is like this: *11-JAN-10*
Sample data to be loaded is :
1|36901|O|173665.47|1996-01-02|5-LOW|Clerk#000000951|0|nstructions sleep furiously among |
Desc Orders
O_ORDERDATE NOT NULL DATEI have tested this by creating a test table and a test control file by omitting this O_ORDERDATE and then everything was fine, data was inserted but don't know how to load this DATE also.
Also not able to understand about POSITION in the control file...?
Regards,
Kam -
Hi,
I've to load data through control_file(.ctl) into oracle table through sqlldr. Oracle 11g, win xp.
as soon as I use - sqlldr dss/dss control=orders.ctl I get error or nothing.
Text file that is generated after loading fails has the following error.
Record 1: Rejected - Error on table ORDERS, column O_ORDERDATE.
ORA-01861: literal does not match format string
I have checked the format of data to be loaded into Orders table is like this : *1996-01-02.*
I checked the format of data in my database by querying sysdate from dual i.e. 10-JAN-10
I thought that changing its format might solve my problem so i tried this:
SQL> alter session set nls_date_format='YYYY-MM-DD';
Session altered.
SQL> select sysdate from dual;
SYSDATE
2010-01-10but still i'm getting the same error. I've to load millions of data. how I can solve this issue.
Please suggest.
Thanks alot.
Best Regads,
Kam
Edited by: kam555 on Jan 10, 2010 11:41 PMPlease refrain from [posting duplicates|http://forums.oracle.com/forums/thread.jspa?threadID=1010735&tstart=0] and mark this post with IGNORE in the subject.
Maybe you are looking for
-
Missing Producer Portal info in the Enterprise Portal
Whenever we make any change to our Producer Portal, BI in this case, the Consumer Portal, EP stops displaying the Fedeated pages or iviews. Anyone trying to access the EP with BI roles either then gets a blank page or it times out. The EP continues t
-
After upgrading to OS X Mavericks, Time Capsule is not recognized
After I upgraded my Mac to OS X Mavericks 10.9, Time Machine stopped backing up to my Airport Time Capsule and now the Mac no longer recongizes the TC device. It is a TC model # A1254, 500GB. Any suggestions for being able to re-connect / re-set-up
-
Help solving this mask bug, its been there for 2 years
https://bugs.adobe.com/jira/browse/SDK-20416 I'm not sure if it is a bug or what. I got no respnse from flex team. I attached swf file and source code so you can easily see what is going on. I listed a workaround but this bug is getting more and more
-
Hi, wen i try using find my iphone it says no location avilable please advise !
hi, wen i try using find my iphone it says no location avilable please advise !
-
Connecting One Environment XI to multiple environment mySap
Hello, I have the Dev XI environment. it is connected with the Mysap DEV ENVIRONMENT. I need to connect the XI DEV environment with MySap QA ENVIRONMENT too. Is it possible? Is there some guide about this? Thanks, Wenner Oliveira