Error xml Oracle on a file

On Oracle 11 g 2, I import an xml file into a table:

INSERT INTO MS386_XML_TEMPLATE

VALUES (SYSDATE, pvNomeFile,

XmlType (bfilename (myDirectory, pvNomeFile), nls_charset_id ('UTF8')));

When I choose on this table, I have the following error:

SELECT TBELENCOPOD. POD

Of

(SELECT XMLCast (TBPOD. POD COLUMN_VALUE AS VARCHAR2 (20)) AS

TABLE (XMLSequence (XMLTYPE (CURSOR

(SELECT * FROM MS386_XML_TEMPLATE)

() .extract('/rowset/row/xml_file/edi_l/trader/idrif idrich/hdr/pod '))) TBPOD

) TBELENCOPOD

LEFT JOIN MS038_METERS TBPOD

ON TBELENCOPOD. POD = TBPOD. POD

WHERE TBPOD. POD IS NULL

GROUP OF TBELENCOPOD. POD;

ORA-31011: ORA-31011: failed to parse XML

ORA-19202: an error has occurred in the processing of XML

LPX-00204: syntax error

Error on line 7

ORA-06512: a "SYS. XMLTYPE", line 343

ORA-06512: line 1

31011 00000 - "XML parsing failed"

* Cause: XML parser returned an error trying to parse the document.

* Action: Check whether the document to parse is valid.

The XML is valid, I had checked with a validator. Thank you very much

Igor

Me stupid (when do I start to actually read what was written)

You have a table with varchar2(), the date and xmltype.

So, how do you think Oracle to convert the xmltype column to xmltype (at least it's a moment)?

So you can get the content out, xmltype but then you have to convert it to xml, it is already XML...

So we need to find another approach to "xmltype (cursor (select * table)).

In principle, you can extract the content in the XML file directly.

For example (untested) something like

select xt.pod
from table tab
      , xmltable ('/edi_l/trader/idrif/hdr',
                      passing tab.XML_FILE
                      columns
                        pod VARCHAR2(20) path 'pod')  xt

Tags: Database

Similar Questions

  • Cannot create a database in Oracle 11 g. TNS Protocol card error.  . Missing ORA files.

    I want to start by saying: I went through several forum threads about errors in Protocol TNS, .ora files, installation guides and you name it.  I am new to Oracle 11 g, and I bought the book for a course of database, I don't take in college;  However, I'm not a newbie to technology and I have SQL experience.  My Oracle experience has been a disaster so far, and I am a tester of application by trade! I spent an entire week, just try to get the software installed correctly before finally creating this discussion on your forums.  So I'm sorry to disrupt your forums.  I know that you have 1,000 other subjects with a similar scope, but I have received no help from Oracle and none of the proposed solutions have previously solved my problem.  Let's get to it.

    My system: 6 core AMD, Windows 7 Ultimate SP1, 16 GB RAM, multiple disk drives, if you need anything else to say.

    I am trying to install software: Oracle 11 g SQL Database Standard Edition (it came with my book SQL Oracle 11 g and I need company for the moment)

    Environment: Windows 2008 Server Virtual Datacenter

    Client VM: VMWare

    Problem in short: when I try to install the software and create a database, everything is successful, until the database Configuration Wizard attempts to finalize the process.  All the prereq check Oracle directories are created and etc.  To the database Configuration Wizard, I always get the following error message:

    ORA-12560: TNS:protocol adapter error

    If I try to launch sqlplus and enter my credentials of the default Oracle, I get the same error (I am basically unable to get to the SQL > screen).  I noticed that I only have a sqlnet.ora file in my folder "OraHome_1/NETWORK/ADMIN", and I have not all listeners or tnsnames file in this directory. The sqlnet.ora file reads as follows:

    sqlnet.ora # Network Configuration file: C:\app\Administrator\product\11.1.0\db_1\network\admin\sqlnet.ora
    # Generated by Oracle configuration tools.

    # This file is actually generated by netca. But if customers can opt for
    # install 'Software Only', this file does not exist and without the native
    authentication #, they will not be able to connect to the database on NT.

    SQLNET. AUTHENTICATION_SERVICES = (NTS)

    NAMES. DIRECTORY_PATH = (TNSNAMES, EZCONNECT)

    I look at my running services and find that I 3 running Oracle services (at this point, I tried to uninstall/reinstall several times, none seems to be a COMPLETE uninstall, while some of these services were not there before...):

    Oracle ORCL VSS Writer Service (started)

    (Disabled) OracleJobSchedulerORCL # I will revive it with no other success

    OracleOraDb11g_home1TNSListener (on the way)

    I tried to launch another listener using the following cmd command, but I still received the TNS error trying to create a database or connect to sqlplus.

    lsnrctl start LISTENER

    I admit, I am quite sleepy at this point, and I'm not figure this tonight.  I'm not having my hand held through the process, but I could really use some help here.  I understand that my VM disk drive is probably fragmented at this point and I'll probably need to start over from a clean installation of OUR.  I also understand that I keep missing a crucial procedure during initial installation because it is quite obvious that this will not work without the listener or tnsname files.  I tried to interpret the samlples, but an example of the syntax would be really useful.  Also, what users to manually configure these standard files?  It seems that a lot of my trouble could have been avoided if the installation had been easier.  On the contrary, the flame of the fact that I'm more efficient with Microsoft, that the fact that I am new to Oracle.  I could just go to mysql, but I want to give a chance to Oracle.  I just need a nudge in the right direction to get database database server installed.

    I really appreciate any idea that anyone can provide.  I know that you have had other similar subjects historically, but none that I found helped me to this day.  I'm a major network, so I understand that TNS is an Oracle proprietary protocol.  I also understand that the listener is required to actively receive information about this port; I even took down my firewall temporarily to make sure it wasn't a problem.  I even understand that connection strings are needed to associate the database Oracle, Oracle with my Microsoft OS and etc.  What I don't understand, why this was so complicated. Help, please.  I'm just tired of banging my head into the wall on this one.

    Your friend.

    Mills J

    I don't really understand Windows, but I think that you must be connected to the machine as a local administrator and a member of a group ora_dba local, nothing to do with the areas he makes. It is a working example of an account that works:

    c:\users\john >

    c:\users\john>c:\Windows\System32\whoami.exe/User /groupes /fo list

    USER INFORMATION

    ----------------

    Username: jwvaio\john

    SID: S-1-5-21-3147636863-431841176-3387327930-1001

    GROUP INFORMATION

    -----------------

    Name of Group: all

    Type: Notorious group

    SID: S-1-1-0

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_ASMDBA

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1012

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ora_dba

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1014

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home1_SYSBACKUP

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1009

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home1_SYSDG

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1010

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home1_SYSKM

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1011

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home2_SYSBACKUP

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1018

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home2_SYSDG

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1019

    Attributes: Mandatory, default, active group

    Name of Group: jwvaio\ORA_OraDb12c_home2_SYSKM

    Type: Alias

    SID: S-1-5-21-3147636863-431841176-3387327930-1020

    Attributes: Mandatory, default, active group

    Group name: BUILTIN\Administrators

    Type: Alias

    SID: S-1-5-32-544

    Attributes: Mandatory, by default, the owner of the group, group Enabled

    Group name: BUILTIN\Users

    Type: Alias

    SID: S-1-5-32-545

    Attributes: Mandatory, default, active group

    Group name: NT NT\Interactif

    Type: Notorious group

    SID: S-1-5-4

    Attributes: Mandatory, default, active group

    Group name: logging CONSOLE

    Type: Notorious group

    SID: S-1-2-1

    Attributes: Mandatory, default, active group

    Group name: NT AUTHORITY\Authenticated users

    Type: Notorious group

    SID: S-1-5-11

    Attributes: Mandatory, default, active group

    Group name: NT AUTHORITY\Ce organization

    Type: Notorious group

    SID: S-1-5-15

    Attributes: Mandatory, default, active group

    Group name: LOCAL

    Type: Notorious group

    SID: S-1-2-0

    Attributes: Mandatory, default, active group

    Group name: NT AUTHORITY\NTLM authentication

    Type: Notorious group

    SID: S-1-5-64-10

    Attributes: Mandatory, default, active group

    Group name: Label\High mandatory mandatory level

    Type: Label

    SID: S-1-16-12288

    Attributes: Mandatory, default, active group

    c:\users\john >

    c:\users\john >

  • REP-3000: internal error from Oracle Toolkit.

    Hi all

    We get below error when try to generate the report in XML format.

    XML_REPORTS_XENVIRONMENT is:
    ORCL/Oracle/ORA/8.0.6/guicommon6/TK60/admin/Tk2Motif_UTF8. RGB

    XENVIRONMENT is set to /orcl/oracle/ora/8.0.6/guicommon6/tk60/admin/Tk2Motif_UTF8.rgb


    NLS_LANG and NLS_NUMERIC_CHARACTERS Environment Variables are:
    American_America.UTF8

    '.,'

    REP-3000: internal error from Oracle Toolkit.

    I can see in the context file that display value is set for the correct server name.

    I can access the simultaneous server using PuTTY.

    When I display the value


    $xterm
    xterm Xt error: can't open display: 10.1.7.160:0.0
    IP concurrent server - 10.1.7.160
    I can't on screen as I can access through PuTTY.

    Details of approx.

    Version of apps - 11.5.10.2
    Version of DB - 11.2.0.1
    OPERATING SYSTEM - IBM AIX 6.1

    Please suggest

    Thank you

    >

    I guess that is not the path. Do I have to create the directory/usr/tmp/XMLTEMP. Y at - it no doc metalink to set up the report for the XML editor.

    Thank you

    Fix. You must create this directory and ensure that the owner of the application (applmgr) is able to write in this directory. If you want to change this location to another directory, please see

    XML editor reports fail with java.io.FileNotFoundException on Temp Directory after cloning [1189764.1 ID]

    Thank you

  • How to write the xml data to a file

    Hi all

    We have a requirement of writing, the xml data in a file in the data directory in the server. Generate xml data using the SQL below.

    SELECT XMLELEMENT ("LINE",
    XMLELEMENT ('CELL', xmlattributes (LIKE 'column name', ' EBIZCZMDL_01'), inventory_item_id).
    XMLELEMENT ('CELL', xmlattributes (AS 'Name of COLUMN', ' EBIZFFMT_01'), attribute29).
    XMLELEMENT ('CELL', xmlattributes ("COMMON" AS "Name of COLUMN"), inventory_item_id |) '' || attribute29 | "ITM")
    "XMLDATA" AS "PRODUCE")
    OF apps.mtl_system_items_b

    When we try to write this query data in a file using UTL_FILE.put_line, the script gives error
    PLS-00306: wrong number or types of arguments in the call to "PUT_LINE '.

    If anyone can help pls...

    Thanks in advance

    The call to dbms_xslprocessor.clob2file is in the cursor for the specific SQL loop.

    This is obviously the problem.
    The file is replaced with each iteration.

    Do not use a cursor at all.

    See the example below, it should be close to your needs:

    DECLARE
    
       l_file_name      VARCHAR2 (30);
       l_file_path      VARCHAR2 (200);
    
       l_xmldoc         CLOB;
    
    BEGIN
    
       l_file_path := '/usr/tmp';
       l_file_name := 'TEST_XREF4.xml';
    
       SELECT XMLElement("xref", xmlattributes('http://xmlns.oracle.com/xref' as "xmlns"),
                XMLElement("table",
                  XMLElement("columns",
                    XMLElement("column", xmlattributes('EBIZFFMT_01' as "name"))
                  , XMLElement("column", xmlattributes('COMMON' as "name"))
                  , XMLElement("column", xmlattributes('EBIZQOT_01' as "name"))
                  , XMLElement("column", xmlattributes('EBIZCZMDL_01' as "name"))
                  , XMLElement("column", xmlattributes('EBIZCZGOLD_01' as "name"))
                  ),
                  XMLElement("rows",
                    XMLAgg(
                      XMLElement("row",
                        XMLElement("cell", xmlattributes('EBIZCZMDL_01' AS "colName"), inventory_item_id)
                      , XMLElement("cell", xmlattributes('EBIZFFMT_01' AS "colName"), attribute29)
                      , XMLElement("cell", xmlattributes('COMMON' AS "colName"), inventory_item_id || '' || attribute29 || 'ITM')
                      )
                    )
                  )
                )
              ).getClobVal()
       INTO l_xmldoc
       FROM apps.mtl_system_items_b
       WHERE attribute29 IS NOT NULL
       ;
    
       dbms_xslprocessor.clob2file(l_xmldoc, l_file_path, l_file_name, nls_charset_id('UTF8'));
    
    END;
    /
    

    BTW, the directory in DBMS_XSLPROCESSOR parameter. CLOB2FILE must be an Oracle Directory object, not a literal path.

  • "Command failed" error in Oracle Discoverer 10g

    Hi all
    I get "Command Failed" when you export XML workbook in discoverer administrator.
    This is the steps I followed.
    Step 1: Connect to Discoverer Administrator and connect database EUL.
    Step 2: Choose file-> export
    Step 3: Choose the objects selected in the layer of the end user option button
    Step 4: Select object drop down and selected Workbooks the workbook
    Setp5: Click on the Browse button to chose the XML path on your computer and look for the button "generate XML for the exported files.

    Please let me know how to solve this problem.
    The "Command failed" error comes only for workbooks cutom, not for oracle seeded ones.

    Kind regards
    Prasad

    Please see (Business area Export in Discoverer 10g Administrator does not work, error "Command failed" [1083374.1 ID]).

    Thank you
    Hussein

  • Webworks Application error 'could not read a file file://.

    I properly packed and loaded my first Webworks app on my Playbook. Now that I have here, I need test and debug. The application works fine on my local IIS computer so I knew that I should make some adjustments for the Playbook. Now that I'm here, I don't know how to do in this regard.

    When I run the application on the Playbook, I get this error as soon as it starts:

    Unknown network error

    Cannot read a file file://

    The application is an HTML5 app that used jquery (not the mobile version again), web services, css and images. I have all the js, css and images files in subfolders. Then when I zipped the applications I have selected all HTML pages and subfolders. I guess that was the correct way to go for that package manager is run without problem.

    I'm new to this kind of things together mobile/tablet for any Adviser is greatly appreciated.

    Thank you

    Rusty

    I have it! my index.html was wrong in the config.xml file. I had written the Index.html file with a top of case 'I' but in the config.xml file, he was using a lowercase "i".

    Thanks for the help.

  • What is this error telling me? Activation context generation failed for "assemblyIdentity1." Error in manifest or policy file "assemblyIdentity2" on the assemblyIdentity3 line.

    Error: (19/10/2012 02:23:06) (Source: SideBySide) (user :)
    Description: Activation context generation failed for "assemblyIdentity1." Error in manifest or policy file "assemblyIdentity2" on the assemblyIdentity3 line.
    The value ' * ' attribute 'language' in the "assemblyIdentity" element is invalid.

    Error: (19/10/2012 02:19:20) (Source: SideBySide) (user :)
    Description: Activation context generation failed for "C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest1." Political or obvious error in the file 'C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest2' on the C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest3 line.
    A component version required by the application conflicts with another version of the component already active.
    Contradictory elements are:
    Component 1: C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest.
    Component 2: C:\Windows\WinSxS\manifests\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_41e6975e2bd6f2b2.manifest.

    Error: (18/10/2012 01:39:02) (Source: SideBySide) (user :)
    Description: Activation context generation failed for "assemblyIdentity1." Error in manifest or policy file "assemblyIdentity2" on the assemblyIdentity3 line.
    The value ' * ' attribute 'language' in the "assemblyIdentity" element is invalid.

    Error: (18/10/2012 01:33:59) (Source: SideBySide) (user :)
    Description: Activation context generation failed for "C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest1." Political or obvious error in the file 'C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest2' on the C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest3 line.
    A component version required by the application conflicts with another version of the component already active.
    Contradictory elements are:
    Component 1: C:\Windows\WinSxS\manifests\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac.manifest.
    Component 2: C:\Windows\WinSxS\manifests\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_41e6975e2bd6f2b2.manifest.

    Hello

    Thanks for posting your question in the Microsoft Community!

    If I understand correctly you found the error in the event viewer.
    Event Viewer is a tool that displays detailed information about the events important (for example, programs that don't start as expected or updates are downloaded automatically) on your computer. The event viewer can be useful when troubleshooting problems and errors with Windows and other programs.
    I would like to ask you a question in order to better understand the issue.
    You did changes to the computer before the show? All newly installed programs?
    An application manifest is an XML file that describes and identifies the shared and private-by-side assemblies that an application should bind to running. These must be the same assembly versions that were used to test the application. Application manifests may also describe the metadata of the files that are private to the application.
    The error seems to be related to the drivers of amd.
    We will visit the amd support link and install the compatible drivers for amd programs and check if this solves the problem.
    We also execute (SFC scan) System File Checker. The tool File Checker system to determine if the problem you are experiencing is caused by one or more system files that are used by Windows, the System File Checker utility analyzes the system files and replaces incorrect versions of system files by using the correct versions.
    Refer to this article.

    How to use the System File Checker tool to fix the system files missing or corrupted on Windows Vista or Windows 7: http://support.microsoft.com/kb/929833


    Hope the helps of the information provided.

    Let us know results also, feel free to post us if you face because of Windows in the future. We would be happy to help you!

  • WebLogic Setup error: "Unable to copy a file" in silent mode

    Hello world

    I try to install the Weblogic on Linux server using silent mode.

    I followed the instructions at http://docs.oracle.com/middleware/1212/core/OUIRF/silent.htm#OUIRF326.

    After successfully creating the response file and oraInst.loc, I enter this command: java-jar wls_121200.jar - silent - /home/weblogic/wls.rsp - invPtrLoc/etc/oraInst.loc response.

    Command line goes like this:

    Check if the speed of the CPU is above 300 MHz.   Real MHz 2526,998 spent

    Check the swap space: must be greater than 512 MB.   Real 10288440 MB passed

    Check if this platform requires a 64-bit JVM.   Real success 64 (64-bit not required)

    Check the temp space: must be greater than 300 MB.   Real 44752 MB passed

    ...

    Reading response file...

    ...

    Expected result: one of the enterprise-4,enterprise-5,enterprise-6,redhat-6,redhat-4,redhat-5,SuSE-10,SuSE-11

    Actual result: business-5

    Full version. The result of this review is: past

    ...

    CertifiedVersions Check: success.

    Checking data... success

    ...

    Copying files...

    The error message occurs here, during file copy process:


    Error.png

    I am stuck on this problem for a while, can anyone help me out of it?

    Thank you!  I really appreciate it!


    Kind regards

    Chris



    Hello

    A user that you use to install weblogic.

    Make sure that the user you are using have enough permission to copy the file and create the directory.

    Use an administrative account / user to install weblogic and check

    It may be useful

  • Cannot open the database: error, ora-03113 end of file communication

    Hi guys,.

    I am facing a problem with my database

    Oracle Linux Tikanga 5 machine
    database: 10.2.0.1
    Error: ora-03113

    I tried to move a log file while inserting data...

    I restored and tried to get back what she recovers with message media recover full but doesnot allow to open the database
    gives the same error: error: ora-03113 end of file communication

    Watch alert_log
    ____________

    ALTER database recover if necessary
    beginning
    Start of recovery Media
    ORA - 264 marked during: alter database recover if necessary
    beginning
    ...
    Fri Jan 9 16:20:18 2013
    2048 MB db_recovery_file_dest_size is 40,79% used. It is a
    user-specified limit on the amount of space that will be used by the present
    for the files related to the recovery of databases and does not reflect the amount of
    space available in the underlying file system or ASM diskgroup.
    Fri Jan 9 16:22:02 2013
    change the list of file restore of database data clear
    Fri Jan 9 16:22:02 2013
    Completed: change the clear list of restore of database data file
    Fri Jan 9 16:22:02 2013
    Edit the list of file restore of database data
    1, 2, 3, 4, 5
    Completed: change the list of file restore of database data
    1, 2, 3, 4, 5
    Fri Jan 9 16:22:02 2013
    ALTER database recover if necessary
    beginning
    Start of recovery Media
    ORA - 264 marked during: alter database recover if necessary
    beginning
    ...
    Fri Jan 9 16:22:07 2013
    change the database open
    Fri Jan 9 16:22:07 2013
    LGWR: FROM PROCESS ARCH
    Arc0 started with pid = 16, OS id = 2049
    Fri Jan 9 16:22:07 2013
    Arc0: Started archiving
    Arc1: Started archiving
    LGWR: FROM PROCESS ARCH COMPLETE
    Arc1 started with pid = 17, OS id = 2051
    Fri Jan 9 16:22:07 2013
    Fix half open fully the valve of the thread 1
    Fri Jan 9 16:22:07 2013
    Errors in the /d1/app/oracle/oradata/orcl/bdump/orcl_lgwr_1966.trc file:
    [ORA-00600: internal error code, arguments: [3712], [1], [1], [0], [445262], [0], [445261],]
    Fri Jan 9 16:22:08 2013
    Errors in the /d1/app/oracle/oradata/orcl/bdump/orcl_lgwr_1966.trc file:
    [ORA-00600: internal error code, arguments: [3712], [1], [1], [0], [445262], [0], [445261],]
    LGWR: termination litigation because of the 470 error
    Instance terminated by LGWR, pid = 1966

    can you please on the same...
    Thank you

    ORA-00600: internal error code, arguments: [3712].

    ORA-00600 is error internal oracle, you need to check metalink support for this.

  • Extract data from Oracle into excel file

    Hello

    I have a requirement where in I need to extract data from Oracle into excel file and the worksheet excel name should be 'given '.
    for example. Excel 'AR Data_DDMMYY' file name and the name of the "Data" sheet excel

    I used the UTL_FILE API to extract the data delimited by tabs that you can open in excel, but it's not exactly an excel file as the name of the worksheet is the same as the name of the file.

    I tried to use utl_file.fcopy and frename.

    Is it possible to do it using PLSQL?

    Select * from version of v$.
    Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bi
    PL/SQL Release 10.2.0.5.0 - Production
    "CORE     10.2.0.5.0     Production"
    TNS for HPUX: Version 10.2.0.5.0 - Production
    NLSRTL Version 10.2.0.5.0 - Production
    Example Code:
    declare
    cursor c is
    select * from scott.emp;
    v varchar2(100);
    f utl_file.file_type;
    
    file_name varchar2(100) := 'AR Data.xls';
    dir varchar2(50) := 'CESDIR191710';
    
    --select * from dba_directories
    
    begin
    
    
    f := utl_file.fopen(dir, file_name, 'W');
    
    v := 'EMPNO'||chr(9)||'ENAME'||chr(9)||'JOB'||chr(9)||'SAL'||chr(9)||'HIREDATE'||chr(9)||'DEPTNO';
    utl_file.put_line(f, v);
    
    for i in c
    loop
    
    v := i.empno||chr(9)||i.ename||chr(9)||i.job||chr(9)||i.sal||chr(9)||i.hiredate||chr(9)||i.deptno;
    utl_file.put_line(f, v);
    
    end loop;
    utl_file.fclose(f);
    
    --utl_file.frename(dir, file_name, dir, replace(file_name, '.xls', '_')||to_char(sysdate, 'MMDDYY')||'.xls', false);
    utl_file.fcopy(dir, file_name, dir, replace(file_name, '.xls', '_')||to_char(sysdate, 'MMDDYY')||'.xls');
    
    end;
    Thank you
    Imran

    Hello

    I tried to change the .xlsx to .xls and it gives a note at the opening of the file "the file you are trying to open, abc.xls, is in a different format that it is specified by the file extension. Check that the file is not corrupted and precedes from a trusted source before you open the file. Do you want to open it now? »

    When you rename the file does not solve your problem.
    Anton Scheffer package generates a file in format xlsx Office 2010. When rename you it with the .xls extension, then Office 2010 will give you the warning that the file format does not match the extension.

    but the requirement has to generate excel 2003 file.

    The xml_spreadsheet package writes a format that was introduced with Office 2003, but you must use .xml as extension in other Office 2010 will give you the same caveat.
    To write the real xls version (binary), you can use Apache POI. You will need to import Java classes in your db and write a PL/SQL wrapper. Or you can use one of the options above, writing the output to a windows server and then use Excel to open and save in the required format.

    You must decide whether it is easier to write the binary xls format or to convince the customer to accept other formats that can be opened with Excel.

    Concerning
    Marcus

  • Error: XML parsing failed because «»

    Error: XML parsing failed because «»

    I have searched for the meaning of this very confusing error message, but all I can find is comments saying I should put verbose = true in my build.properties file.
    I use JDeveloper 11.1.1.5 to build if it uses a file build.properties this isn't one that I created.

    When I click on the error it just takes me to the top of the file bpel that I have an error in (or so he claims).

    Can someone explain please once and for all what this error message means and then suggest ways to fix this?

    Thank you.

    This error occurs when there is a wsdl file or xsd double in your project. Remove one double and its references... you should be happy to compile your project successfully.

  • Problem loading xml using sql loader file

    I am trying to load data into the table test_xml (xmldata XMLType)

    I have an xml file and I want any file to load in a single column

    When I use the following control file and run from the command-line as follows
    sqlldr $1@$TWO_TASK direct control=$XXTOP/bin/LOAD_XML.ctl = true; :

    DOWNLOAD THE DATA
    INFILE *.
    TRUNCATE INTO TABLE test_xml
    XmlType (XMLDATA)
    FIELDS
    (
    tank fill ext_fname (100),
    XMLDATA LOBFILE (ext_fname) COMPLETED BY expressions of folklore
    )
    START DATA
    U01/appl/apps/apps_st/appl/XXTop/12.0.0/bin/file. XML

    the file is loaded in the table perfectly.

    Unfortunately I can't hard-code the name of file as file name will be changed dynamically.

    so I removed the block

    START DATA
    U01/appl/apps/apps_st/appl/XXTop/12.0.0/bin/file. XML

    control file and tried to run by giving the following command line path

    sqlldr $1@$TWO_TASK control=$XXTOP/bin/LOAD_XML.ctl direct data=/u01/APPL/apps/apps_st/appl/xxtop/12.0.0/bin/file.xml = true;

    But strangely it attempts to load each line of the xml file in the table instead of the whole file

    Please find the log of the program with the error

    ------------------------------------------------------------------
    Loading XML through SQL * Loader begins
    ------------------------------------------------------------------
    SQL * Loader-502: cannot open the data file ' <? XML version = "1.0"? > ' table field TEST_XML XMLDATA
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file '< root >' XMLDATA field table TEST_XML
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file '< ScriptFileType >' field XMLDATA table TEST_XML
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file ' < Type > forms < / Type > ' table field TEST_XML XMLDATA
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file ' < / ScriptFileType > ' table field TEST_XML XMLDATA
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file '< ScriptFileType >' field XMLDATA table TEST_XML
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file ' < Type > PLL < / Type > ' table field TEST_XML XMLDATA
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file ' < / ScriptFileType > ' table field TEST_XML XMLDATA
    SQL * Loader-553: file not found
    SQL * Loader-509: System error: no such file or directory
    SQL * Loader-502: cannot open the data file '< ScriptFileType >' field XMLDATA table TEST_XML

    Please help me how can I load full xml in a single column using command line without Hardcoding in the control file

    Published by: 907010 on January 10, 2012 02:24

    But strangely it attempts to load each line of the xml file in the table instead of the whole file

    Nothing strange, that the data parameter specifies the file containing the data to load.
    If you use the name of the XML here, the control file will try to interpret each line of XML as being separate ways.

    The traditional approach this is to have the name of the file stored in another file, say filelist.txt and use, for example:

    echo "/u01/APPL/apps/apps_st/appl/xxtop/12.0.0/bin/file.xml" > filelist.txt
    sqlldr $1@$TWO_TASK control=$XXTOP/bin/LOAD_XML.ctl data=filelist.txt direct=true;
    
  • Error trying to move the file using the file adapter

    Hi, I'm looking for a script to move the file to one remote folder to another by file adapter as described in the topic 4.5.11.1 to http://download.oracle.com/docs/cd/E21764_01/integration.1111/e10231/adptr_file.htm#CHDGFAAB. But I get the below error:

    input > < message > <
    < Invoke1_FileMove_InputVariable > < part name = "Empty" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" > < empty xmlns = "http://xmlns.oracle.com/pcbpel/adapter/opaque/" / > < / piece > < / Invoke1_FileMove_InputVariable > < / input > < fault >
    < bpelFault > < faultType > 0 < / faultType > < bindingFault xmlns = "http://schemas.oracle.com/bpel/extension" > < a name = "summary" part > < summary > Exception is is produced when the link has been invoked.
    Exception occurred during invocation of the JCA binding: "* JCA binding run operations reference 'FileMove' have to: Exception occurred when setting has been invoked.*.
    * Exception occurred during invocation of the JCA binding: "* failed to instantiate InteractionSpec oracle.tip.adapter.file.outbound.FileReadInteractionSpec reason: cannot set JCA WSDL perte.*."
    * The WSDL of JCA perte.* definition error *.
    * The setSourcePhysicalDirectory property is not set to oracle.tip.adapter.file.outbound.FileReadInteractionSpec *.
    * Please check the spelling of the perte.* *.
    ".
    The called JCA adapter threw an exception of resource.
    Please review the error message above carefully to determine a resolution.
    ".
    The called JCA adapter threw an exception of resource.
    Please review the error message above carefully to determine a resolution.
    < Summary / > < / part > < part name = "detail" > < details > can not set the WSDL JCA property.
    Error setting property of WSDL JCA.
    SetSourcePhysicalDirectory property is not set to oracle.tip.adapter.file.outbound.FileReadInteractionSpec
    Please check the spelling of the property.
    < / detail > < / part > < part name = "code" > < null code > < / code > < / piece > < / bindingFault > < / bpelFault > < / fault > < faultType >
    < message > 0 < / message > < / faultType > < / messages >

    Please provide any idea if someone tried it.

    Thank you
    RPS

    Hi rps.

    Your interaction-spec className seems to be incorrect (FileReadInteractionSpec).

        
     .....
        
    

    Please try with the specifications of interaction above and let me know the results.

    Kind regards
    Neeraj Sehgal

  • CMDTUX_CAT:754: ERROR: error parsing of the configuration files

    Hi Tuxedo Experts,
    I have compiled and related sample code Tuxedo client and server (simpapp). According to the README, the next steps is running y tmboot command. It starts smoking simpserv Server? If this is not the case, how can I start that?

    In addition, when I ran this 'tmboot-y' command, I get the error:
    ===========================================
    $ tmboot y

    tmboot: internal error: CMDTUX_CAT:754: ERROR: error parsing of the configuration files



    tmboot: internal error: CMDTUX_CAT:1360: ERROR: configuration file not found
    ===========================================

    Could you please help me with that.

    Thank you and best regards,
    Ahsan Asghar

    Hey Ahsan,

    Well, the error message says tmboot cannot find TUXCONFIG. If the TUXCONFIG environment variable has not been set or the tmloadcf command has not completed successfully to create TUXCONFIG. Whenever you login, you will need to run the tux.env file to set all necessary environment variables. If tmloadcf finishes successfully, it should have printed one or more of the error messages.

    Kind regards
    Todd little
    Chief Architect of Oracle Tuxedo

  • ERROR - 01034:ORACLE IS NOT AVAILABLE

    Hi all
    I am also facing similar pblm.

    I installed Oracle10G on Linux system.

    I tried to connect to sqlplus using cmd:

    sqlplus / as sysdba

    His connection, but after giving the sql commands, it displays "ERROR - 01034:oracle is not available. How can we solve this pblm. Here's mu .bash_profile


    --------------------------------------------------------------------------------

    # .bash_profile

    # Get the aliases and functions
    If [~/.bashrc - f]; then
    . ~/.bashrc
    FI

    # Specific programs startup and user environment

    $PATH = path: $HOME/bin

    export PATH
    umask 022

    PATH = / bin: / usr/bin: / usr/local/bin: / usr/X11R6/bin
    LD_LIBRARY_PATH = / usr/lib: / usr/X11R6/lib
    ORACLE_BASE = / home/oracle/oracle
    ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_10
    ORACLE_SID = orcl2
    PATH = $ORACLE_HOME/bin: $PATH

    export PATH LD_LIBRARY_PATH
    export ORACLE_SID ORACLE_BASE ORACLE_HOME
    DISPLAY = 192.168.10.215:0.0;
    Export DISPLAY
    ~


    --------------------------------------------------------------------------------

    and my/etc/oratab is like this:




    --------------------------------------------------------------------------------

    # This file is used by ORACLE utilities. It is created by root.sh
    # update by the database when creating Configuration Wizard
    # a database.

    # A colon, ':', is used as the field terminator. A new line ends
    # entry. Lines starting with a pound sign, "#", are comments.
    #
    # Entries are of the form:
    # $ORACLE_SID: $ORACLE_HOME: N | Y >:
    #
    # Fields in the first and the second are the identifier system and home
    Directory of # database respectively. The third filed indicates
    # for the utility dbstart the database must, 'Y', or not,
    # ', Being high at system boot time.
    #
    # Multiple entries with the same $ORACLE_SID are not allowed.
    #
    #
    ORCL:/Home/Oracle/Oracle/product/10.2.0/db_7:Y
    orcl2:/Home/Oracle/Oracle/product/10.2.0/db_10:Y
    ~

    --------------------------------------------------------------------------------

    What is my tnsnames.ora file


    --------------------------------------------------------------------------------
    tnsnames.ora # Network Configuration file: /home/oracle/oracle/product/10.2.0/db_10/network/admin/tnsnames.ora
    # Generated by Oracle configuration tools.

    ORCL =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = china3) (PORT = 1521))
    (CONNECT_DATA =
    (SERVER = DEDICATED)
    (SERVICE_NAME = orcl2)
    )
    )

    EXTPROC_CONNECTION_DATA =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = CIP)(KEY = EXTPROC1))
    )
    (CONNECT_DATA =
    (SID = PLSExtProc)
    (PRESENTATION = RO)
    )
    )

    --------------------------------------------------------------------------------

    Please help me, thanks in advance

    Hello
    Is your database in the open State?
    sqlplus / as sysdba

    startup
    

    Best regards
    Phil

Maybe you are looking for

  • Portege 4000: After HARD drive replacing WinXP installation stopped

    Drive HARD original of my old laptop Portege 4000 just crashed. I went to the local computer store and bought a new Samsung 40 GB HDD (no part no MP0402H) what they recommended. First of all, I have problem to him have partitioned and formatted when

  • Satellite A200 - 1 L 5 PSAE3E-02300JIT problem with audio and integrated webcam

    Hi all! I recently changed from Windows Vista to Windows 7. Everything is ok except for the webcam and audio. I can no longer access the webcam and the sound is really low, even if the volume is at its maximum. The caps do not work (no sounds out of

  • How to enable IR on the Satellite A500/031

    Does anyone know how to activate the IR port of a Toshiba A500/031 (part - PSAR9A-031001 number)? I can't find how to turn it on.

  • HP 8500: print and scan the doctor

    When I start printing & doctor Scan, it displays a printer that I did more.  The printer has been uninstalled 2 years ago, and there is no remaining software I know.  It has an IP address, but can't get it anywhere in Control Panel to remove the insc

  • Satellite M70-147 and Toshiba E-mouse (PX1215E-1NAC)

    Two weeks ago, I bought a Satellite M70-147 and a Toshiba E-mouse (PX1215E-1NAC). Two of them again.So far I've failed to do E - the mouse to do its job. I applied the installation instructions to the letter, but nothing helped.I discovered that they