Error in using SQLLDR LKM

I am trying to load fixed length flat file into Oracle table in ODI by using LKM File to Oracle (SQLLDR).
But getting below error in Call sqlldr step,
org.apache.bsf.BSFException: exception from Jython:
Traceback (most recent call last):
  File "<string>", line 22, in <module>
Load Error: See C:\Aditya\ODI\SQL_Loader/TARIFF_SERVICE.log for details
    at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:146)
    at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.execInBSFEngine(SnpScriptingInterpretor.java:322)
    at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.exec(SnpScriptingInterpretor.java:170)
    at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java:2472)
    at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:47)
    at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:1)
    at oracle.odi.runtime.agent.execution.TaskExecutionHandler.handleTask(TaskExecutionHandler.java:50)
    at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2913)
    at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2625)
    at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:558)
    at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:464)
    at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:2093)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:366)
    at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:216)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:300)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:292)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:855)
    at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:126)
    at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:82)
    at java.lang.Thread.run(Thread.java:662)
Caused by: Traceback (most recent call last):
  File "<string>", line 22, in <module>
Load Error: See C:\Aditya\ODI\SQL_Loader/TARIFF_SERVICE.log for details
    at org.python.core.PyException.fillInStackTrace(PyException.java:70)
    at java.lang.Throwable.<init>(Throwable.java:181)
    at java.lang.Exception.<init>(Exception.java:29)
    at java.lang.RuntimeException.<init>(RuntimeException.java:32)
    at org.python.core.PyException.<init>(PyException.java:46)
    at org.python.core.PyException.doRaise(PyException.java:219)
    at org.python.core.Py.makeException(Py.java:1166)
    at org.python.core.Py.makeException(Py.java:1170)
    at org.python.pycode._pyx13.f$0(<string>:59)
    at org.python.pycode._pyx13.call_function(<string>)
    at org.python.core.PyTableCode.call(PyTableCode.java:165)
    at org.python.core.PyCode.call(PyCode.java:18)
    at org.python.core.Py.runCode(Py.java:1204)
    at org.python.core.Py.exec(Py.java:1248)
    at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:172)
    at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:144)
    ... 19 more
TARIFF_SERVICE.log is not getting created.
Code generated is,
import java.lang.String
import java.lang.Runtime as Runtime
from jarray import array
import java.io.File
import os
import re
ctlfile = r"""C:\Aditya\ODI\SQL_Loader/TARIFF_SERVICE.ctl"""
logfile = r"""C:\Aditya\ODI\SQL_Loader/TARIFF_SERVICE.log"""
outfile = r"""C:\Aditya\ODI\SQL_Loader/TARIFF_SERVICE.out"""
oracle_sid=''
if len('XE')>0: oracle_sid = '@'+'XE'
loadcmd = r"""sqlldr 'HR/<@=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
# Init Vars
nbIns = 0
nbRej = 0
nbNull = 0
strprt = ""
maxAllowedError = r"""0"""
c = 0
flag = 0
# Open log file
f = open(logfile, "r")
try:
    lines = f.readlines()
    for line in lines:
        if line.rstrip().upper().endswith(r"""HR.TC$_0SAS_TARIFF_SERVICEREPLACE:""".upper()):
            flag = 1
            c = 0
        if flag == 1:
            if c > 0 and c <= 4:
                if c == 1 :
                    nbIns = int(re.findall("\d+", line)[0])
                elif c == 2:
                    nbRej = int(re.findall("\d+", line)[0])
                elif c == 4:
                    nbNull = int(re.findall("\d+", line)[0])
                    break
        c+=1
    strprt = "\n\tIns:\t%s\n\tReject:\t%s\n\tNullField:\t%s" % (nbIns, nbRej, nbNull)
finally:
    f.close()
# if some rows has been rejected due to invalide data, check KM option LOA_ERRORS
if rc == 2:
    if nbRej > int(maxAllowedError):
        raise strprt
        break
Can anyone suggest how to resolve this issue?
Thanks,
Aditya

Hi
i am facing same issue did any body find any solution for it
Hi 1005380,
Thanks for quick respond.
Source(position based file so i cant change the phsical length)
name,type,physical length,logical length,-,-,recordCount
pading
String
1
1
50
null
2
journal_name
String
2
50
50
null
journal_line_number
String
52
6
50
null
segment1
String
58
6
50
null
segment2
String
64
8
50
null
segment3
String
72
5
50
null
segment4
String
77
3
50
null
segment5
String
80
1
50
null
segment6
String
81
4
50
null
segment7
String
85
3
50
null
segment8
String
88
5
50
null
line_desc
String
93
240
50
null
debit_amount
String
333
15
50
null
credit_amount
String
348
15
50
null
Target(DB)
order,name,type,logicalLength,scale,Source mapping fields
55
ENTERED_DR
NUMBER
0
-127
Debit_amt(sorce)
56
ENTERED_CR
NUMBER
0
-127
credit_amt(source)
60
REFERENCE1
VARCHAR2
100
0
journalname(source)
142
CUSTOM_ATTRIBUTE1
VARCHAR2
150
0
segment1(s)
143
CUSTOM_ATTRIBUTE2
VARCHAR2
150
0
segment2(s)
144
CUSTOM_ATTRIBUTE3
VARCHAR2
150
0
segment3(s)
145
CUSTOM_ATTRIBUTE4
VARCHAR2
150
0
segment4(s)
146
CUSTOM_ATTRIBUTE5
VARCHAR2
150
0
segment5(s)
147
CUSTOM_ATTRIBUTE6
VARCHAR2
150
0
segment6(s)
148
CUSTOM_ATTRIBUTE7
VARCHAR2
150
0
segment7(s)
149
CUSTOM_ATTRIBUTE8
VARCHAR2
150
0
segment8(s)
i am omitting padding and line_desc from source for mapping.
Note : 1)even i am mapping single column eg: journal_name and reference1 for more than 1000 records i am getting the Error(Number format exception).for 999 records it is picking up and it is not throwing any error.
2)for 999 records i mapped all the fields its working fine,if pass more than 999 records it throwing error.
knowledge Modules:
LKM File to SQL and IKM SQL Control Append
Execution Steps:
loading Drop work table ,Create work table and error at Load data
Error code:
Source Code:
select
journal_name
C3_JOURNAL_NAME,
segment1
C4_SEGMENT1,
segment2
C5_SEGMENT2,
segment3
C6_SEGMENT3,
segment4
C7_SEGMENT4,
segment5
C8_SEGMENT5,
segment6
C9_SEGMENT6,
segment7
C10_SEGMENT7,
segment8
C11_SEGMENT8,
debit_amount
C1_DEBIT_AMOUNT,
credit_amount
C2_CREDIT_AMOUNT
from
TABLE
/*$$SNPS_START_KEYSNP$CRDWG_TABLESNP$CRTABLE_NAME=ADA_ENTRY_STG_LINESSNP$CRLOAD_FILE=/C:/DavidNithin/GL_Abstraction/adaoasisla.dat.07012013_13h23.txtSNP$CRFILE_FORMAT=FSNP$CRFILE_SEP_FIELD=0x0009SNP$CRFILE_SEP_LINE=0ASNP$CRFILE_FIRST_ROW=0SNP$CRFILE_ENC_FIELD=SNP$CRFILE_DEC_SEP=SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=padingSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=1SNP$CRLENGTH=1SNP$CRPRECISION=50SNP$CRREC_CODE_LIST=2SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=journal_nameSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=2SNP$CRLENGTH=50SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=journal_line_numberSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=52SNP$CRLENGTH=6SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment1SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=58SNP$CRLENGTH=6SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment2SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=64SNP$CRLENGTH=8SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment3SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=72SNP$CRLENGTH=5SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment4SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=77SNP$CRLENGTH=3SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment5SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=80SNP$CRLENGTH=1SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment6SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=81SNP$CRLENGTH=4SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment7SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=85SNP$CRLENGTH=3SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=segment8SNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=88SNP$CRLENGTH=5SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=line_descSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=93SNP$CRLENGTH=240SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=debit_amountSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=333SNP$CRLENGTH=15SNP$CRPRECISION=50SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=credit_amountSNP$CRTYPE_NAME=STRINGSNP$CRLINE_OFFSET=348SNP$CRLENGTH=15SNP$CRPRECISION=50SNP$CR$$SNPS_END_KEY*/
Target Code:
insert into ODI.C$_0MNA_ENTERY_STG_LINES_ADA
  C3_JOURNAL_NAME,
  C4_SEGMENT1,
  C5_SEGMENT2,
  C6_SEGMENT3,
C7_SEGMENT4,
C8_SEGMENT5,
C9_SEGMENT6,
C10_SEGMENT7,
C11_SEGMENT8,
C1_DEBIT_AMOUNT,
C2_CREDIT_AMOUNT
values
:C3_JOURNAL_NAME,
:C4_SEGMENT1,
:C5_SEGMENT2,
:C6_SEGMENT3,
:C7_SEGMENT4,
:C8_SEGMENT5,
:C9_SEGMENT6,
:C10_SEGMENT7,
:C11_SEGMENT8,
:C1_DEBIT_AMOUNT,
:C2_CREDIT_AMOUNT
Error message:
java.lang.NumberFormatException: For input string: "1,000"
  at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
  at java.lang.Integer.parseInt(Inte

Similar Messages

  • LKM Error while using sqlldr

    Can somone help me regarding this error.
    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)

    You can find the script below..
    OPTIONS (
         SKIP=1,
         ERRORS=0,
         DIRECT=FALSE
    LOAD DATA
    INFILE "D:/ODI/Data Mapping Test Files/Training/XXCNV_TRAINING_SOURCE.txt"
    BADFILE "D:/ODI/Data Mapping Test Files/Work Schema/XXCNV_TRAINING_SOURCE.bad"
    DISCARDFILE "D:/ODI/Data Mapping Test Files/XXCNV_TRAINING_SOURCE.dsc"
    DISCARDMAX 1
    INTO TABLE APPS.C$_0XXCNV_TRAINING_ORACLE_SOUR
    FIELDS TERMINATED BY X'3B'
         C1_CUSTOMER_NAME,
         C2_CUSTOMER_NUMBER,
         C3_PAYMENT_TERM,
         C4_CUSTOMER_POSTALCODE,
         C5_CUSTOMER_CONTACT,
         C6_CUSTOMER_ADDRESS1,
         C7_CUSTOMER_START_DATE
    )

  • Getting Error while using  LKM File to Oracle(SQLLDR) KM in ODI

    Hi All ,
    Could anyone please help me out on this error which i am getting while using LKM File to Oracle(SQLLDR)
    My Scenario :
    1. I have my CSV file created in one location with some records .
    2. Created a new interface having this CSV file as source(File Technology) and Table as target (Oracle technology)
    3. Here i want to get the contents from csv and store into the target table by using SQLLDR .For that i am using this KM- LKM File to Oracle(SQLLDR)
    4. By Executing the Interface i am getting following error at step 6 -call sqlldr
    org.apache.bsf.BSFException: exception from Jython:
    Traceback (most recent call last):
      File "<string>", line 22, in <module>
    Load Error: See E:\demo1\file/SALES.log for details
      at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:146)
      at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.execInBSFEngine(SnpScriptingInterpretor.java:322)
      at com.sunopsis.dwg.codeinterpretor.SnpScriptingInterpretor.exec(SnpScriptingInterpretor.java:170)
      at com.sunopsis.dwg.dbobj.SnpSessTaskSql.scripting(SnpSessTaskSql.java:2472)
      at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:47)
      at oracle.odi.runtime.agent.execution.cmd.ScriptingExecutor.execute(ScriptingExecutor.java:1)
      at oracle.odi.runtime.agent.execution.TaskExecutionHandler.handleTask(TaskExecutionHandler.java:50)
      at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2913)
      at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2625)
      at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:577)
      at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:468)
      at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:2128)
      at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:366)
      at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:216)
      at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:300)
      at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:292)
      at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:855)
      at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:126)
      at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:82)
      at java.lang.Thread.run(Thread.java:662)
    Caused by: Traceback (most recent call last):
      File "<string>", line 22, in <module>
    Load Error: See E:\demo1\file/SALES.log for details
      at org.python.core.PyException.fillInStackTrace(PyException.java:70)
      at java.lang.Throwable.<init>(Throwable.java:181)
      at java.lang.Exception.<init>(Exception.java:29)
      at java.lang.RuntimeException.<init>(RuntimeException.java:32)
      at org.python.core.PyException.<init>(PyException.java:46)
      at org.python.core.PyException.doRaise(PyException.java:219)
      at org.python.core.Py.makeException(Py.java:1166)
      at org.python.core.Py.makeException(Py.java:1170)
      at org.python.pycode._pyx2.f$0(<string>:59)
      at org.python.pycode._pyx2.call_function(<string>)
      at org.python.core.PyTableCode.call(PyTableCode.java:165)
      at org.python.core.PyCode.call(PyCode.java:18)
      at org.python.core.Py.runCode(Py.java:1204)
      at org.python.core.Py.exec(Py.java:1248)
      at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:172)
      at org.apache.bsf.engines.jython.JythonEngine.exec(JythonEngine.java:144)
      ... 19 more
    Here the sales.log file is not created in the above directory .I am not getting  where it is actually went wrong.
    I searched for the solution and i could not find any.Please help me out as it is high priority for me.
    I tried to run SQL*Loader through command prompt and i am able to generate the data in the target table and not getting it through ODI.
    Atleast is there any workaround .Please suggest me.
    Environment Details: ODI_11.1.1.7.0, Oracle DB 11g
    Thanks,
    keerthi

    Which agent are you using to execute?
    Standalone? If standalone, did you start it with OPMN?  I've seen such issues with standalone agent started with OPMN.
    Generally these kind of issues occur when you try to run with standalone agent started with OPMN.
    Because OPMN does not have access to the environment shell variables PATH or ORACLE_HOME and therefore the sqlldr.exe binary (or other Oracle product binary) is not found for execution.
    In this case, you need to specify PATH and ORACLE_HOME variables in opmn.xml file like below for your agent(say "MyStandaloneAgent" in this case)
    <ias-component id="MyStandaloneAgent">
    <process-type id="odiagent" module-id="CUSTOM">
      <environment>
         <variable id="ORACLE_HOME" value="C:\oracle\product\11.2.0\client_1"/>
          <variable id="PATH" value="C:\oracle\product\11.2.0\client_1\BIN;$PATH"/>
    After that, start and stop the agent and try the execution once again.

  • Error when load sptial data by using sqlldr

    Currently, I have a shapeFile, so I have used shp2sdo tool to convert shapeFile to Oracle Spatial database. But when using sqlldr tool, I get the following errors:
    ----- Log file content ------
    SQL*Loader: Release 10.2.0.1.0 - Production on Sat Mar 24 09:13:07 2007
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    Control File: /home/oracle/street.ctl
    Data File: /home/oracle/street.ctl
    Bad File: /home/oracle/street.bad
    Discard File: none specified
    (Allow all discards)
    Number to load: ALL
    Number to skip: 0
    Errors allowed: 50
    Bind array: 64 rows, maximum of 10000000 bytes
    Continuation: 1:1 = 0X23(character '#'), in next physical record
    Path used: Conventional
    Table STREET, loaded from every logical record.
    Insert option in effect for this table: TRUNCATE
    TRAILING NULLCOLS option in effect
    Column Name Position Len Term Encl Datatype
    ID FIRST * | CHARACTER
    NAME NEXT * | CHARACTER
    NULL if NAME = BLANKS
    GEOM DERIVED * COLUMN OBJECT
    *** Fields in GEOM
    SDO_GTYPE NEXT * | CHARACTER
    SDO_SRID NEXT * | CHARACTER
    SDO_ELEM_INFO DERIVED * VARRAY
    Terminator string : '|/'
    *** Fields in GEOM.SDO_ELEM_INFO
    X FIRST * | CHARACTER
    *** End of fields in GEOM.SDO_ELEM_INFO
    SDO_ORDINATES DERIVED * VARRAY
    Terminator string : '|/'
    *** Fields in GEOM.SDO_ORDINATES
    X FIRST * | CHARACTER
    *** End of fields in GEOM.SDO_ORDINATES
    *** End of fields in GEOM
    Record 1: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 2: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 3: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 4: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 5: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 6: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    Record 7: Rejected - Error on table STREET, column GEOM.SDO_ELEM_INFO.X.
    error converting data
    ORA-01722: invalid number
    -------- this is my control file ---------------
    LOAD DATA
    INFILE *
    TRUNCATE
    CONTINUEIF NEXT(1:1) = '#'
    INTO TABLE STREET
    FIELDS TERMINATED BY '|'
    TRAILING NULLCOLS (
    ID,
    NAME      NULLIF NAME = BLANKS,
    GEOM COLUMN OBJECT
    SDO_GTYPE INTEGER EXTERNAL,
    SDO_SRID INTEGER EXTERNAL,
    SDO_ELEM_INFO VARRAY TERMINATED BY '|/'
    (X FLOAT EXTERNAL),
    SDO_ORDINATES VARRAY TERMINATED BY '|/'
    (X FLOAT EXTERNAL)
    BEGINDATA
    1|A|
    #2002|8307|
    #1|2|1|/
    #106.408265|10.461029|106.409036|10.461789|106.409561|10.462392|
    #106.410520|10.463381|106.411527|10.464443|106.412017|10.464956|
    #106.412563|10.465536|106.413615|10.466630|106.414564|10.467624|
    #106.415333|10.468458|106.415749|10.468869|106.416368|10.469524|
    #106.417304|10.470526|106.418107|10.471318|/
    2|B|
    #2002|8307|
    #1|2|1|/
    #106.410156|10.461118|106.406821|10.463133|106.405549|10.463909|/
    3|C|
    #2002|8307|
    #1|2|1|/
    #106.405221|10.464159|106.404133|10.464773|106.403267|10.465291|
    #106.402926|10.465558|106.402158|10.465981|/
    4|D|
    #2002|8307|
    #1|2|1|/
    #106.402341|10.460738|106.403378|10.461422|106.403476|10.461504|
    #106.403562|10.461580|106.403633|10.461660|106.403768|10.461844|
    #106.404904|10.463687|106.405034|10.463842|106.405130|10.463947|
    #106.405221|10.464017|/
    5|E|
    #2002|8307|
    #1|2|1|/
    #106.405443|10.463815|106.406002|10.462394|/
    Have anyone can help me? Thanks

    I've seen folks work around similar problems by temporarily changing their NLS parameters (warning: you probably don't want to do this on a heavily used or production system). I know you said you changed them, but it might be worth another try.
    On NT save the registry entry for NLS_LANG. I think it is at:
    HKEY_LOCAL_MACHINE->SOFTWARE->ORACLE->KEY_YOURORACLEHOME
    Make the NLS_LANG registry value AMERICAN_AMERICA.WE8MSWIN1252
    Restart the database.
    Load the data
    Reset the registry entry
    Restart the database.

  • Data error while loading data using SQLLDR

    Hi Gurus,
    Kindly let em know the possible reasons for getting the below error returned by SQLLDR after loading data:
    x no of rows not loaded due to data errors in SQLLDR
    Could it be due to issues in control file?

    you'll find it well explained here :
    http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14215/part_ldr.htm#i436326
    http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14215/ldr_concepts.htm#i1004846

  • Error during call sqlldr - ODI version 11.1.1.3 and java 1.6.0_30

    Hey All,
    I have scroll thru forums for resolution of similar issue but no luck. Here is the problem this is working fine in ODI version 11.1.1.5, Except the file is mapped to local drive.
    Now below is the error message from ODI 11.1.1.3, Trying to use LKM File to Oracle(SQLLDR) and here is the error
    ODI-1226: Step LD_PARTNER_USING_SQLLDR fails after 1 attempt(s).
    ODI-1240: Flow LD_PARTNER_USING_SQLLDR fails while performing a Loading operation. This flow loads target table DRM_USER_PARTNER_NEW.
    Caused By: org.apache.bsf.BSFException: exception from Jython:
    Traceback (innermost last):
    File "<string>", line 33, in ?
    Load Error: See \\Cdpwa01a0600\e$\Hyperion\DRM\Loadfile/LD_USER_PARTNER.log for details
    here is the generated code from call sqlldr session task
    import java.lang.String
    import java.lang.Runtime as Runtime
    from jarray import array
    import java.io.File
    import os
    import re
    def reportnbrows():          
         f = open(r"\\Cdpwa01a0600\e$\Hyperion\DRM\Loadfile/LD_USER_PARTNER.log", 'r')
         try:
              for line in f.readlines():
                   if line.find("MAXIMUM ERROR COUNT EXCEEDED")>=0 :
                        raise "MAXIMUM ERROR COUNT EXCEEDED", "See %s for details" % logfile
         finally:
              f.close()
    ctlfile = r"""\\Cdpwa01a0600\e$\Hyperion\DRM\Loadfile/LD_USER_PARTNER.ctl"""
    logfile = r"""\\Cdpwa01a0600\e$\Hyperion\DRM\Loadfile/LD_USER_PARTNER.log"""
    outfile = r"""\\Cdpwa01a0600\e$\Hyperion\DRM\Loadfile/LD_USER_PARTNER.out"""
    oracle_sid=''
    if len('d1odi1')>0: oracle_sid = '@'+'d1odi1'
    loadcmd = r"""D:\Oracle\product\11.2.0\client_1\bin\sqlldr 'MDM_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()
    what am i missing?
    Thanks.
    Shri.

    thanks for you reply.. this is what i have hardcoded in the KM for testing purpose. gives me back the error
    org.apache.bsf.BSFException: exception from Jython:
    Traceback (innermost last):
    File "<string>", line 13, in ?
    Load Error, error in the sqlldr step
    import java.lang.String
    import java.lang.Runtime as Runtime
    from jarray import array
    import java.io.File
    import os
    import re
    ospath=(r'D:\Oracle\product\11.2.0\client_1\bin\sqlldr control=e:\Hyperion\DRM\Loadfile\LD_USER_PARTNER.ctl log=e:\Hyperion\DRM\Loadfile\LD_USER_PARTNER.log userid=mdm_stage/xxxxxx@d1odi1')
    rc=os.system(ospath)
    if rc <> 0 and rc <> 2:
    raise "Load Error, error in the sqlldr step"
    Thanks.

  • Getting ORA-22805 when trying to load XML file using SQLLDR

    I'm trying to learn the basics of XML since we'll be getting XML files in the near future. I'm using one of the sample schemas that comes with XMLSPY. I loaded this schema into an 11g Oracle DB using XMLSPY:
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- edited with XML Spy v4.0 NT beta 1 build Jun 13 2001 (http://www.xmlspy.com) by Alexander Falk (Altova, Inc.) -->
    <schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:ipo="http://www.altova.com/IPO" targetNamespace="http://www.altova.com/IPO" elementFormDefault="unqualified" attributeFormDefault="unqualified">
         <annotation>
              <documentation>
    International Purchase order schema for Example.com
    Copyright 2000 Example.com. All rights reserved.
    </documentation>
         </annotation>
         <!-- include address constructs -->
         <include schemaLocation="address.xsd"/>
         <element name="purchaseOrder" type="ipo:PurchaseOrderType"/>
         <element name="comment" type="string"/>
         <complexType name="PurchaseOrderType">
              <sequence>
                   <element name="shipTo" type="ipo:Address"/>
                   <element name="billTo" type="ipo:Address"/>
                   <element ref="ipo:comment" minOccurs="0"/>
                   <element name="Items" type="ipo:Items"/>
              </sequence>
              <attribute name="orderDate" type="date"/>
         </complexType>
         <complexType name="Items">
              <sequence>
                   <element name="item" minOccurs="0" maxOccurs="unbounded">
                        <complexType>
                             <sequence>
                                  <element name="productName" type="string"/>
                                  <element name="quantity">
                                       <simpleType>
                                            <restriction base="positiveInteger">
                                                 <maxExclusive value="100"/>
                                            </restriction>
                                       </simpleType>
                                  </element>
                                  <element name="price" type="decimal"/>
                                  <element ref="ipo:comment" minOccurs="0"/>
                                  <element name="shipDate" type="date" minOccurs="0"/>
                             </sequence>
                             <attribute name="partNum" type="ipo:Sku"/>
                        </complexType>
                   </element>
              </sequence>
         </complexType>
         <simpleType name="Sku">
              <restriction base="string">
                   <pattern value="\d{3}-[A-Z]{2}"/>
              </restriction>
         </simpleType>
    </schema>
    Then I created an XMLType table:
    CREATE TABLE purchaseOrder OF XMLType
    XMLSCHEMA "ipo.xsd" ELEMENT "purchaseOrder"
    I'm trying to load the sample XML file ipo.xml into purchaseOrder using SQLLDR. This is ipo.xml:
    <?xml version="1.0"?>
    <!-- edited with XMLSPY v2004 rel. 4 U (http://www.xmlspy.com) by Mr. Nobody (Altova GmbH) -->
    <ipo:purchaseOrder xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ipo="http://www.altova.com/IPO" orderDate="1999-12-01" xsi:schemaLocation="http://www.altova.com/IPO
    ipo.xsd">
         <shipTo export-code="1" xsi:type="ipo:EU-Address">
              <ipo:name>Helen Zoe</ipo:name>
              <ipo:street>47 Eden Street</ipo:street>
              <ipo:city>Cambridge</ipo:city>
              <ipo:postcode>126</ipo:postcode>
         </shipTo>
         <billTo xsi:type="ipo:US-Address">
              <ipo:name>Robert Smith</ipo:name>
              <ipo:street>8 Oak Avenue</ipo:street>
              <ipo:city>Old Town</ipo:city>
              <ipo:state>AK</ipo:state>
              <ipo:zip>95819</ipo:zip>
         </billTo>
         <Items>
              <item partNum="833-AA">
                   <productName>Lapis necklace</productName>
                   <quantity>2</quantity>
                   <price>99.95</price>
                   <ipo:comment>Need this for the holidays!</ipo:comment>
                   <shipDate>1999-12-05</shipDate>
              </item>
              <item partNum="748-OT">
                   <productName>Diamond heart</productName>
                   <quantity>1</quantity>
                   <price>248.90</price>
                   <ipo:comment>Valentine's day packaging.</ipo:comment>
                   <shipDate>2000-02-14</shipDate>
              </item>
              <item partNum="783-KL">
                   <productName>Uncut diamond</productName>
                   <quantity>7</quantity>
                   <price>79.90</price>
                   <shipDate>2000-01-07</shipDate>
              </item>
              <item partNum="238-KK">
                   <productName>Amber ring</productName>
                   <quantity>3</quantity>
                   <price>89.90</price>
                   <ipo:comment>With no inclusions, please.</ipo:comment>
                   <shipDate>2000-01-07</shipDate>
              </item>
              <item partNum="229-OB">
                   <productName>Pearl necklace</productName>
                   <quantity>1</quantity>
                   <price>4879.00</price>
                   <shipDate>1999-12-05</shipDate>
              </item>
              <item partNum="128-UL">
                   <productName>Jade earring</productName>
                   <quantity>5</quantity>
                   <price>179.90</price>
                   <shipDate>2000-02-14</shipDate>
              </item>
         </Items>
    </ipo:purchaseOrder>
    This is what's in the control file:
    LOAD DATA
    INFILE *
    INTO TABLE purchaseOrder TRUNCATE
    xmltype(xmldata)
    FIELDS
    xmldata LOBFILE (CONSTANT ipo.xml)
    BEGINDATA
    0
    The load fails with:
    Record 1: Rejected - Error on table PURCHASEORDER.
    ORA-22805: cannot insert NULL object into object tables or nested tables
    Another question I have is, how do we know how many records (0's) to specify in the control file? In this case there's only one but when real files are used we won't know how many are in the file.
    Thanks for your help!

    The concept was "Don't use SQL*Loader to parse XML".
    You can use SQL*Loader to load an entire XML document into the DB. That is fine. You can do the same via BFILENAME to read in files from disk as well.
    If you want to parse XML, do that from within Oracle via PL/SQL and/or SQL. The solution depends upon your version of Oracle and what is good enough for you in terms of performance.
    So the basics are
    a) How am I getting the information?
    b) How am I getting in into Oracle?
    c) How do I want to parse it?
    As I see the schema, it only allows for one ipo:purchaseOrder node in the document, since that is the root node. If you have multiple in the incoming file, you no longer have valid XML, both per the schema and because you have no single root node. You have an XML fragment, which must be treated different.
    Just trying to understand the question since I now realize it does not agree with what the schema in your initial example shows.

  • How to show an image stored by using SQLLDR as BLOB in ORACLE 10g

    Hi!
    i used SQLLDR to upload images from localhost to my oracle db,
    i saves theme as BLOB`s.
    my problem is:
    i can not view them correctly, showing it using the code below, i get:
    gtìSNEvR=Cm¯ö¾ÆTÿmÖØÏs_û«¬ú ÿSê¯HwýÓ ›[[ü/ñŠÝßSº‡—¢
    does any know what to do?? can help me??
    thank you!
    A.H.S.
    <?php
    echo "<p>Attempting database connection...</p></p>";
    $db_conn = ocilogon("username", "password", "ORACLE_SID");
    if (!$db_conn)
    echo "...FAILED. Check the username, passwd, dbstring given in this script are valid or not.</p>";
    if (OCIError($db_conn))
    $erra=OCIError($db_conn);
    dodberror("SQL Error: $erra $erra[message]");
            exit;
          else
            echo "<p>Connected...</p></p>";
    $table_name="images";
    $stmt = ociparse($db_conn, "select * from $table_name" );
         if (!$stmt)
            echo '<p>parsing error</p></p>';
          if (!ociexecute($stmt,OCI_DEFAULT))
            echo "<font color='red'><p>query execute error!</p></font>";
           echo "<table border=1 cellspacing='0' width='50%'>\n";
           $ncols = OCINumCols($stmt);
           echo "<tr>\n";
           for ($i = 1; $i <= $ncols; $i++) {
                $column_name  = OCIColumnName($stmt,$i);
                echo "<td><b>$column_name</b></td>\n";
           while (OCIFetch($stmt))
               echo "<tr>\n";
            for ($i = 1; $i <= $ncols; $i++)
              $column_name  = OCIColumnName($stmt,$i);
              $column_value = OCIResult($stmt,$i);
              if($column_name=="DATA")  
              //Header("content-type: image/jpg");
               $image = "$column_value->load()";
               echo $column_value;    // gives OBJECT!
               echo "<td><img src='$image' width='48' height='48' align='middle' border='0' alt='not found'> </td>\n";
              //echo "<td><img src='$column_value.jpg' width='48' height='48' a-lign='middle' border='0' alt='not found'> </td>\n"; //works 100%
              //$c1 = '<IMG height=128 width=600 SRC="http://host/' . $row[2] . '">';
                //if ($row[image]) { 
              //header("Content-Type: $row[image_type]"); 
              //print "$row[image]";
                else
              echo "<td><b>$column_value</b></td>\n";
            echo "</tr>\n";
          echo "</tr>\n";
           echo "</table>\n";
          OCIFreeStatement($stmt);
          OCILogoff($db_conn);
        ?>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Do you need to uncomment one of the header() functions? Make sure
    it is called before any text or whitespace is sent.
    Look at the example in PHP 5 Code to Upload and Retrieve an Image (aka BLOB) with Oracle
    -- cj

  • Using sqlldr when source data column is 4000 chars

    I'm trying to load some data using sqlldr.
    The table looks like this:
    col1 number(10) primary key
    col2 varchar2(100)
    col3 varchar2(4000)
    col4 varchar2(10)
    col5 varchar2(1)
    ... and some more columns ...
    For current purposes, I only need to load columns col1 through col3. The other columns will be NULL.
    The source text data looks like this (tab-delimited) ...
    col1-text<<<TAB>>>col2-text<<<TAB>>>col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    END-OF-RECORD
    There's nothing special about the source data for col1 and col2.
    But the data for col3 is (usually) much longer than 4000 chars, so I just need to truncate it to fit varchar2(4000), right?
    The control file looks like this ...
    LOAD DATA
    INFILE 'load.dat' "str 'END-OF-RECORD'"
    TRUNCATE
    INTO TABLE my_table
    FIELDS TERMINATED BY "\t"
    OPTIONALLY ENCLOSED BY '"'
    TRAILING NULLCOLS
    col1 "trim(:col1)",
    col2 "trim(:col2)",
    col3 char(10000) "substr(:col3,1,4000)"
    I made the column 3 specification char(10000) to allow sqlldr to read text longer than 4000 chars.
    And the subsequent directive is meant to truncate it to 4000 chars (to fit in the table column).
    But I get this error ...
    Record 1: Rejected - Error on table COL3.
    ORA-01461: can bind a LONG value only for insert into a LONG column
    The only solution I found was ugly.
    I changed the control file to this ...
    col3 char(4000) "substr(:col3,1,4000)"
    And then I hand-edited (truncated) the source data for column 3 to be shorter than 4000 chars.
    Painful and tedious!
    Is there a way around this difficulty?
    Note: I cannot use a CLOB for col3. There's no option to change the app, so col3 must remain varchar2(4000).

    You can load the data into a staging table with a clob column, then insert into your target table using substr, as demonstated below. I have truncated the data display to save space.
    -- load.dat:
    1     col2-text     col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    XYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    END-OF-RECORD-- test.ctl:
    LOAD DATA
    INFILE 'load.dat' "str 'END-OF-RECORD'"
    TRUNCATE
    INTO TABLE staging
    FIELDS TERMINATED BY X'09'
    OPTIONALLY ENCLOSED BY '"'
    TRAILING NULLCOLS
    col1 "trim(:col1)",
    col2 "trim(:col2)",
    col3 char(10000)
    SCOTT@orcl_11gR2> create table staging
      2    (col1 varchar2(10),
      3       col2 varchar2(100),
      4       col3 clob)
      5  /
    Table created.
    SCOTT@orcl_11gR2> host sqlldr scott/tiger control=test.ctl log=test.log
    SCOTT@orcl_11gR2> select * from staging
      2  /
    COL1
    COL2
    COL3
    1
    col2-text
    col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    XYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    1 row selected.
    SCOTT@orcl_11gR2> create table my_table
      2    (col1 varchar2(10) primary key,
      3       col2 varchar2(100),
      4       col3 varchar2(4000),
      5       col4 varchar2(10),
      6       col5 varchar2(1))
      7  /
    Table created.
    SCOTT@orcl_11gR2> insert into my_table (col1, col2, col3)
      2  select col1, col2, substr (col3, 1, 4000) from staging
      3  /
    1 row created.
    SCOTT@orcl_11gR2> select * from my_table
      2  /
    COL1
    COL2
    COL3
    COL4       C
    1
    col2-text
    col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    more-col3-text
    XYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
    1 row selected.

  • Using Sqlldr to load VARRAYs!!!!!!!

    HI,
    I've created a collection type within the database the description of which reads as follows.....
    SQL> desc LISTVARCHAR
    LISTVARCHAR VARRAY(200) OF VARCHAR2(4000)
    But when I try to insert a value of more than 255 characters using sqlldr, it seems to fail giving the following message, but works fine from within sqlplus!
    Record 1: Rejected - Error on table TESTER, column COL1.
    Field in data file exceeds maximum length
    ****** Sample Data:
    |ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUV|
    Shouldn't this Column take as many as 4000 characters for each element within that VARRAY? Please let me know if I'm missing anything.
    Thanks a lot for your time
    Chandra M.

    You will able to find good information about it in this document :
    http://download-east.oracle.com/docs/cd/B10501_01/server.920/a96652.pdf
    Joel P�rez

  • Using sqlldr to load CLOB data from DB2

    I am stuck trying to resolve this problem. I am migrating data from DB2 to Oracle. I used DB2 export to extract the data specifying lobsinfile clause. This created all the CLOB data in one file. So a typical record has a column with a reference to the CLOB data. "OUTFILE.001.lob.0.2880/". where OUTFILE.001.lob is the name specified in the export command and 0 is the starting position in the file and 2880 is the length of the first CLOB.
    When I try to load this data using sqlldr I'm getting a file not found.
    The control file looks something like this:
    clob_1 FILLER char(100),
    "DETAILS" LOBFILE(clob_1) TERMINATED BY EOF,
    I'm using Oracle 11gR2 and DB2 9.7.5
    Your help is appreciated.

    OK..here are additional details. Some names have changed but the idea is the same. Also the sqlldr is executing in the same directory as the data files and the control file
    Primary data file is VOIPCACHE.dat Secondary datafile (file with lob data) is VOIPCACHE.001.lob
    Control Fileload data
    infile 'VOIPCACHE.dat'
    badfile 'VOIPCACHE.bad'
    discardfile 'VOIPCACHE.dsc'
    replace into table VOIPCACHE
    fields terminated by ',' optionally enclosed by '"' TRAILING NULLCOLS
    (KEY1 "rtrim(:KEY1)",
    FIELD8,
    clob_1 FILLER char (100),
    "DATA" LOBFILE(clob_1) TERMINATED BY EOF)
    Snippet from Log file
    IELD7 NEXT * , O(") CHARACTER
    FIELD8 NEXT * , O(") CHARACTER
    CLOB_1 NEXT 100 , O(") CHARACTER
    (FILLER FIELD)
    "DATA" DERIVED * EOF CHARACTER
    Dynamic LOBFILE. Filename in field CLOB_1
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.0.0/' for field "DATA" table VOIPCACHE
    SQL*Loader-553: file not found
    SQL*Loader-509: System error: No such file or directory
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.0.47/' for field "DATA" table VOIPCACHE
    SQL*Loader-553: file not found
    SQL*Loader-509: System error: No such file or directory
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.47.47/' for field "DATA" table VOIPCACHE
    SQL*Loader-553: file not found
    SQL*Loader-509: System error: No such file or directory
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.94.58/' for field "DATA" table VOIPCACHE
    SQL*Loader-553: file not found
    SQL*Loader-509: System error: No such file or directory
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.152.58/' for field "DATA" table VOIPCACHE
    SQL*Loader-553: file not found
    SQL*Loader-509: System error: No such file or directory
    SQL*Loader-502: unable to open data file 'VOIPCACHE.001.lob.210.206/' for field "DATA" table VOIPCACHE
    This is repeated for each record
    sqlldr command
    sqlldr userid=${SCHEMA}/${PASSWD}@$ORACLE_SID control=${CTLDIR}/${tbl}.ctl log=${LOGDIR}/${tbl}.log direct=true errors=50
    I dont think the variables are important here
    -EC

  • Load Multiple Table using SQLLDR

    Hi,
    We are trying to Load Multiple Table using SQLLDR in same loading session.
    Here's a snippet of our script:
    LOAD DATA INFILE '/u07/dd/yyyy_mm_dd.dat'
    append INTO TABLE table1
    WHEN STORE_NO != ' '
    STORE_NO position(1:5) ,
    TR_DATE position(6:27) DATE "mm/dd/yy
    truncate INTO TABLE table2
    WHEN STORE_NO != ' '
    STORE_NO position(1:5) ,
    TR_DATE position(6:27) DATE "mm/dd/yy
    Now upon execution this gives an error saying truncate shouldn't be present before 2nd INTO Clause. The script runs fine if we do same operation say Append / Replcae / Truncate on both tables. My Question here is can we have SQLLDR perform two diff operations (Append & Truncate in our case) in one session?
    Thanks
    Chinmay
    PS: Referred to http://www.orafaq.com/wiki/SQL*Loader_FAQ#Can_one_load_data_from_multiple_files.2F_into_multiple_tables_at_once.3F already

    No.
    did you read the syntax diagram and the paragraph below:
    "When you are loading a table, you can use the INTO TABLE clause to specify a table-specific loading method (INSERT, APPEND, REPLACE, or TRUNCATE) that applies only to that table. That method overrides the global table-loading method. The global table-loading method is INSERT, by default, unless a different method was specified before any INTO TABLE clauses."

  • How to use sqlldr in linux

    i need to load an excel file in oracle database using sqlldr
    how can i do that
    i am not clear about the control file uses and its creation
    thanks :-)

    These links were not of much help as i already went through it
    my prob is i dont get any error when i run sqlldr
    sqlldr userid=scott/tiger control=emp.ctlPotential problems:
    1. Your command "sqlldr userid=scott/tiger control=emp.ctl" doeas not include data file name (where is the data for import) because there this file is not specified in .ctl file.
    So define "data" prameter in sqlldr command or add infile <filename> to .ctl as following:
    LOAD DATA
    INFILE <replace by filename>
    APPEND INTO TABLE emp1
    id INTEGER EXTERNAL TERMINATED BY "," ENCLOSED BY '"',
    ename CHAR TERMINATED BY "," ENCLOSED BY '"'
    )2. Your .ctl is not appropriate for data structure.
    This .ctl is expecting following data structure:
    "1", "James Bond"
    "2", " Miss Moneypenny"
    "3", "M"
    "4", "Q"
    ... and so on.or
    "1", "James Bond",
    "2", " Miss Moneypenny",
    "3", "M",
    "4", "Q",
    ... and so on."userid=scott/tiger" - I assume you are loading data on the same machine where the databse serer is located. Right?
    The links are appropriate! It is official documentantion and all information I gave you are part of this document.

  • Problem while using sqlldr..

    Hi All,
    I have one shell script which picks up one csv file and load the data into oracle table using sqlldr..the problem is this script is running fine in one env but for the same csv file it is not loading the data into table.It is just skipping sqlldr call..I have checked all the path defined in the script.All are set in both the env.
    ErrorExit()
    echo $1
    echo "\nPlease contact TF administrator\n"
    echo "Press Enter to continue....."
    exit 1
    LOG_FILE=${DBR_LOG}/`basename $0 | cut -f1 -d"."`_kplus_`date +%d%m%Y`.log
    TFTMP_FL="${DBR_LOG}/TFKP$$.sql"
    cat <<!xxx > $TFTMP_FL
    set pause off
    set echo on
    set feedback on
    set verify on
    delete dbt_c_tf_kplus_load where brch_code='$BRCD';
    delete dbt_c_tf_kplus_recn where brch_code='$BRCD';
    commit;
    exit;
    !xxx
    sqlplus -s $PRM_CONNECT_STRING @$TFTMP_FL
    rm -f $TFTMP_FL
    echo " Deleted old data from load and recon tables...."|tee -a ${LOG_FILE}
    export KPLUS_LOG=`cd ${DBR_LOG}/../kplus;pwd`
    export DAY=`echo $PRM_RUN_DATE|cut -c 7-8`
    export MON=`echo $PRM_RUN_DATE|cut -c 5-6`
    export YEAR=`echo $PRM_RUN_DATE|cut -c 1-4`
    export KPLUS_FILE=TF2_${BRCD}_${DAY}${MON}${YEAR}.csv
    if [ ! -f ${KPLUS_LOG}/${KPLUS_FILE} ]
    then
    ErrorExit "\nTF KPLUS Recon: ${KPLUS_FILE} is not avialable"
    fi
    CTL_FILE=${DBR_LOG}/tfkplus_${BRCD}.ctl
    #BRCH_CODE constant "${BRCD}",
    cat <<!EOF >> ${CTL_FILE}
    options (errors=100000, silent=(discards))
    load data
    append
    into table DBT_C_TF_KPLUS_LOAD
    fields terminated by '|' optionally enclosed by '"'
    TRAILING NULLCOLS
    BRCH_CODE constant "${BRCD}",
    BRCH_NAME CHAR(35),
    KPLUS_REF_ID CHAR(10),
    CUS_MST_NO FILLER,
    APPLN_NAME constant "KPLUS",
    KPLUS_DEAL_TYPE CHAR(1),
    OS_AMT CHAR(20),
    CUR_CODE CHAR(3),
    START_DATE DATE "YYYY/MM/DD",
    MAT_DATE DATE "YYYY/MM/DD",
    REMARKS CHAR(100)
    !EOF
    ORA_NLS33=${ORA_HOME}/ocommon/nls/admin/data ; export ORA_NLS33
    sqlldr $PRM_CONNECT_STRING control=${CTL_FILE} data=${KPLUS_LOG}/${KPLUS_FILE} bad=${DBR_LOG}/tfkprecn_${BRCD}.bad log=${DBR_LOG}/tfkprecn_${BRCD}.log discard=${DBR_LOG}/tfkprecn_${BRCD}.dis
    echo " Uploading of KPLUS data into TF tables is complete..."|tee -a ${LOG_FILE}
    rm -rf ${CTL_FILE}

    Thanks..I am getting problem in sqlldr because other part of shell script is executing fine..I can not use -x because the env where i am getting problem is production env and we don't have any kind of access.

  • Error while using P2V in Oracle VM 2.2 version

    Error while using P2V in Oracle VM 2.2 version
    I tried using this option by using the steps given on one link but it didnt worked...
    Error:
    code 404, message No permission to list directory.
    I ve tried giving full permissions on for /OVS on Server but invain.
    Can U pls help me...
    Thanks in advance.
    Edited by: user10310678 on Sep 16, 2009 3:32 AM

    user10310678 wrote:
    I am using beta version. Oracle VM Manager 2.2.0If you have a beta version of 2.2, then you should be an Oracle employee. Please ask this question on an internal mailing list. If you are not an Oracle employee, please ask the employee that gave you this beta. As this is a beta, some functionality may not be operational yet, so I can't answer why this particular feature seems not to work.

Maybe you are looking for

  • DEtailed scheduling planning board - scalling of objects in the charts

    Hi, I am wandering if there is a possibility of changing the scale in the graphical planning board in APO PPDS, eg. in the resource chart. in the way that I could change the scale just for a certain period of time or one object. for example: the plan

  • How do I save an imovie project that I can't export from a 4th gen ipod touch?

    My daughter created a movie in imovie.  We can't get it to export.  It says that there isn't enough space left.  I have deleted everything off the touch except for imovie.  When I started there were 1.2 gb free.  For some reason it went down to 110 m

  • Can't access iCloud email after update to 10.7.4

    After updating to System 10.7.4, I can't access my iCloud email account on any of my devices (computer and iPhone 4S). The servers are not recognizing my email password, which is the same as my Apple ID password.  I can log in to iCloud using Safari

  • Cant view .avi movie?!?

    hello, i have never been able to open an ".avi" movie on my computer, and it has just finally gotten to the point where i am frusterated. does anybody know why this is, or what i can do? I am running quicktime 7.1.3. When i open it it says error open

  • Having problem with my hp officejet j6480 all-in-one printer

    i am having problem with my HP officejet j6480 all-in-one printer it prints very slow the operating system is windows 7  32-bits i download full driver software but that did not fix the problem This question was solved. View Solution.