Need help to retrieve the XML file

Hello

I'm new to xml query and I need help badly. I have a file xml with the following content. I need help to extract data as:

beginTimelocalDnmeasObjLdnhdlcRxErrAborthdlcRxErrCRChdlcRxErrLackOfBufs
2015 07-28 T 14: 45:00 + 03:00ERSGSN01MagId.SlotId.E1/T1Trunk.FractionId=2.8.6.1240010200
2015 07-28 T 14: 45:00 + 03:00ERSGSN01MagId.SlotId.E1/T1Trunk.FractionId=2.9.3.1000
2015 07-28 T 14: 45:00 + 03:00ERSGSN01MagId.SlotId.E1/T1Trunk.FractionId=2.9.4.1000

and the XML data I have are:

<? XML version = "1.0" encoding = "UTF-8"? >

<? XML-stylesheet type = "text/xsl" href = "MeasDataCollection.xsl"? >

" < measCollecFile xmlns =" http://www.3GPP.org/FTP/specs/archive/32_series/32.435#measCollec ">

< fileFormatVersion = "32.435 V9.0" fileHeader vendorName = "Ericsson" >

< fileSender / >

< measCollec beginTime = "2015-07 - 28 T 14: 45:00 + 03:00" / >

< / fileHeader >

< measData >

< managedElement localDn = "ERSGSN01" / >

< measInfo measInfoId = ' E1/T1, hdlc' >

< job jobId = "Meas_E1T1_all" / >

< duration granPeriod = "PT900S" endTime = "2015-07 - 28 T 15: 00:01 + 03:00" / >

< duration repPeriod = "PT900S" / >

< p measType = "1" > hdlcRxErrAbort < / measType >

< p measType = "2" > hdlcRxErrCRC < / measType >

< p measType = "3" > hdlcRxErrLackOfBufs < / measType >

< p measType = "4" > hdlcRxErrMaxFrameLen < / measType >

< p measType = "5" > hdlcRxErrNonOctetAlign < / measType >

< p measType = "6" > hdlcRxErrQueue < / measType >

< p measType = "7" > hdlcRxOK < / measType >

< p measType = "8" > hdlcRxOctets < / measType >

< p measType '9' = > hdlcTxOK < / measType >

< p measType = "10" > hdlcTxOctets < / measType >

< measValue measObjLdn="MagId.SlotId.E1/T1Trunk.FractionId=2.8.6.1" >

< p r = "1" > 2400 / < r >

< p r '2' = > 1020 / < r >

< p r = "3" >/< r > 0

< p r = "4" >/< r > 0

< p r = "5" > </r > 0

< p r = "6" >/< r > 0

< p r = "7" >/< r > 0

< p r = "8" > 0 </r >

< p r '9' = > 295 / < r >

< p r = "10" > 4130 / < r >

< / measValue >

< measValue measObjLdn="MagId.SlotId.E1/T1Trunk.FractionId=2.9.3.1" >

< p r = '1' >/< r > 0

< p r = "2" >/< r > 0

< p r = "3" >/< r > 0

< p r = "4" >/< r > 0

< p r = "5" > </r > 0

< p r = "6" >/< r > 0

< p r = "7" >/< r > 0

< p r = "8" > 0 </r >

< p r '9' = > 295 / < r >

< p r = "10" > 4130 / < r >

< / measValue >

< measValue measObjLdn="MagId.SlotId.E1/T1Trunk.FractionId=2.9.4.1" >

< p r = '1' >/< r > 0

< p r = "2" >/< r > 0

< p r = "3" >/< r > 0

< p r = "4" >/< r > 0

< p r = "5" > </r > 0

< p r = "6" >/< r > 0

< p r = "7" >/< r > 0

< p r = "8" > 0 </r >

< p r '9' = > 295 / < r >

< p r = "10" > 4130 / < r >

< / measValue >

< / measInfo >

< / measData >

< fileFooter >

< measCollec = endTime "2015-07 - 28 T 15: 00:01 + 03:00" / >

< / fileFooter >

< / measCollecFile >

Help, please. I tried to select a value using the following xml query which does not lead to any output:

WITH t AS (SELECT xmltype (bfilename('SGSN_STAT_ERICSSON', 'A20150728.1445+0300-20150728.1500+0300_Meas_E1T1_all.52'), nls_charset_id('UTF-8')) FROM dual xmlcol)

SELECT beginTime, localDn, measObjLdn, hdlcRxErrAbort, hdlcRxErrCRC, hdlcRxErrLackOfBufs

T, XMLTABLE

(XMLNAMESPACES ('http://www.3gpp.org/ftp/specs/archive/32_series/32.435#measCollec' as 'ns1'), )

' / measCollecFile'

passage xmlcol

columns

beginTime PATH VARCHAR2 (32) ' / measCollec/@beginTime',

localDn PATH VARCHAR2 (32) ' / measData/managedElement@localDn',

measObjLdn PATH VARCHAR2 (32) ' / measData/measInfo/measValue@measObjLdn',

["hdlcRxErrAbort PATH VARCHAR2 (32) ' / measData/measInfo/measValue/r[@p="1 ']',

["hdlcRxErrCRC PATH VARCHAR2 (32) ' / measData/measInfo/measValue/r[@p="2 ']',

"[" hdlcRxErrLackOfBufs PATH VARCHAR2 (32) ' / measData/measInfo/measValue/r[@p="3 ']"

)

Sincere greetings

Either way, using an XQuery FLWOR expression:

select x.*
from xmltable(
       xmlnamespaces(default 'http://www.3gpp.org/ftp/specs/archive/32_series/32.435#measCollec')
     , 'for $h in /measCollecFile
          , $v in $h/measData/measInfo/measValue
        return element row {
          $h/fileHeader/measCollec/@beginTime
        , $h/measData/managedElement/@localDn
        , $v/@measObjLdn
        , element r1 {$v/r[@p="1"]}
        , element r2 {$v/r[@p="2"]}
        , element r3 {$v/r[@p="3"]}
        }'
       passing xmltype(bfilename('TEST_DIR', 'test.xml'), nls_charset_id('AL32UTF8'))
       columns beginTime           timestamp with time zone path '@beginTime'
             , localDn             varchar2(32)             path '@localDn'
             , measObjLdn          varchar2(80)             path '@measObjLdn'
             , hdlcRxErrAbort      number                   path 'r1'
             , hdlcRxErrCRC        number                   path 'r2'
             , hdlcRxErrLackOfBufs number                   path 'r3'
     ) x ;

Tags: Database

Similar Questions

  • Need help to read the xml file and place it in a table.

    Nice day!

    Here is the configuration. I have a xml file from another source which will call a stored procedure in my database (which I am supposed to create). This is a first for me, I've never done development pl/sql or worked with xml. :(

    That's what I hoped to accomplish, if there is a better way, that I am open to him.
    In short, to have a stored procedure that takes the xml file (transmitted by third parties via the call, no url must be a file), creates a temporary table and populates the two columns needed. Then, the SP will make a select join with the temporary table and other data available in another schema. Once the completed table selection will be truncated and dropped. SP farm.

    Details:
    DB: Oracle 11.2.0.1 RAC.
    Charset: AL32UTF8
    Example of XML: (nearly 10,000 lines like this in production)
    "< MerchantID report =" "#" name = 'Conversion detail report' ReportStartDate = '2011-09-27 12:00:00GMT' ReportEndDate = '2011-09-27 21:38:13GMT"Version ="1.1"> < Conversion = '1234567891234567 D' MerchantReferenceNumber Convertingdate =" 2011-09-27 13:39:02 "RequestID ="1234567891234567891234"> < OriginalDecision > REVIEW < / OriginalDecision > < NewDecision > ACCEPT < / NewDecision > < Reviewer > testusr < / examiner > < ReviewerComments > no reason to reject. < / ReviewerComments > < Notes > < Note Date = "2011-09-27 13:39:02" AddedBy = "testusr" comment = "Took possession" / > < / Notes > < queue > Digital Review < / queue > < profile > Digital orders QA < / profile > < / Conversion > "
    ...
    < / report >

    What I tried.
    I found a tutorial: http://it.toolbox.com/blogs/oracle-guide/oracle-and-xml-in-action-a-real-world-example-5319 I tried and was able to make it work. But I could not duplicate the results with my xml file. So I looked away and have had no success. :( I'm not a developer, so I'm really bad...

    I found a note of support: (how to load an XML file into a Database Table using DBMS_XMLSave unaided Bfile [227476.1 ID]) and couldn't make it work.

    I found some online then Odie son xml and tried these but slipped and couldn't get my versions of these great answers to work for me.

    Then... I'm here now and hoping that someone could walk me through this.


    I tinkered this SP (it doesn't have to be that way, the suggestions are greatly appreciated)

    create or replace procedure xml_to_table (call_1 call_2) as

    Start
    run immediately "CREATE GLOBAL TEMPORARY TABLE XMLType IMRPT
    --(clé primaire contrainte-imrpt_pk (MerchantReferenceNumber))
    XmlType store as xml binary basicfile
    -(high compression)
    virtual columns
    (MerchantReferenceNumber as (xmlcast (xmlquery ('/ Conversion/MerchantReferenceNumber ' from object_value content back) as VARCHAR2 (32))))
    , NewDecision as (xmlcast (xmlquery ('/ Conversion/NewDecision ' from object_value content back) as VARCHAR2 (10)))
    )
    -ON COMMIT PRESERVE ROWS

    run immediately 'save xml as a file on the local system?'

    insert into IMRPT (MerchantReferenceNumber, NewDecision)

    run immediately "join select statement.
    run immediately 'truncate table IMRPT.
    run immediately "drop table IMRTP.

    end;
    /

    On my last test, I tried to select just in the xml file using this:

    DECLARE
    indomdoc DBMS_XMLDOM. DOMDocument;
    innode DBMS_XMLDOM. DOMNode;
    myParser DBMS_XMLPARSER.parser;
    buf VARCHAR2 (2000);
    BEGIN
    myParser: = DBMS_XMLPARSER.newParser;

    DBMS_XMLPARSER.setBaseDir (myparser, 'XML_DIR');
    DBMS_XMLPARSER. Parse (myParser, "test.xml");

    indomdoc: = DBMS_XMLPARSER.getDocument (myParser);

    -just to test content
    innode: = DBMS_XMLDOM.makeNode (indomdoc);
    DBMS_XMLDOM.writeToBuffer (innode, buf);
    Dbms_output.put_line (BUF);

    dbms_xmldom.freeDocument (indomdoc);
    dbms_xmlparser.freeParser (myParser);
    END;
    /

    It was another accident and burn.

    Any help would be appreciated.

    Thank you

    Like I said:

    Here is an example using a REF CURSOR variable ( you will need to declare a plus for your actual procedure )

    Your procedure has two parameters, you must declare two variables to hold the two REF CURSOR ;)

    DECLARE
    
      v_filename      VARCHAR2(50) := 'DMReport.xml';
      v_rc1            SYS_REFCURSOR;
      v_rc2            SYS_REFCURSOR;
    
      v_order_name       VARCHAR2(100);
      v_reason_text      VARCHAR2(100);
    
    BEGIN
    
      xml2table(v_filename, v_rc1, v_rc2);
    
      commit;
    
      loop
        fetch v_rc1 into v_order_name;
        exit when v_rc1%notfound;
        dbms_output.put_line('ORDER_NAME='||v_order_name);
      end loop;
    
      close v_rc1;
    
      loop
        fetch v_rc2 into v_order_name, v_reason_text;
        exit when v_rc2%notfound;
        dbms_output.put_line('ORDER_NAME='||v_order_name||', REASON_TEXT='||v_reason_text);
      end loop;
    
      close v_rc2;
    
    END;
    /
    

    If you test this in SQL * Plus, do not forget to SET SERVEROUTPUT ON to see the result.

  • Need help with loading the XML file

    Hello

    I spent reviewing the web/forums for an example on how to do this for a few days now.  I managed to get this working in Flash Pro easily enough, but I think I'm missing something when I want to do the same thing in Flex.

    Basically, I want to load an XML file and then set the values of the text of labels 5, equal to the data in the XML file.

    So I have a button created in MXML and have put the following click event:

    Click = "dsSetup (Event)" "

    I also stated the following:

    public var myRequest:URLRequest = new URLRequest ("assets/myFile.xml");   folder located under the CBC in project

    public var myLoader:URLLoader = new URLLoader();

    public var myXML:XML;

    My function that loads is as follows:

    public function dsSetup(event:MouseEvent):void

    {

         trace ("dsSetup");

    myXML = new XML (myLoader.data);

    H3. Text = myXML.source.itemA;

    H4.text = myXML.source.itemB;

    H5.text = myXML.source.itemC;

    H7.text = myXML.source.itemD;

    H8.text = myXML.source.itemE;

    currentState = "MainMenu";

    }

    myLoader.addEventListener (Event.COMPLETE, dsSetup);   I think that this line is no longer as I put it in the MXML

    myLoader.load (myRequest);

    It's the way I did in Flash and it worked fine, but I must be missing something when it comes to Flex.

    Can you explain or point me to a good tutorial that shows how to load XML in Flex code?

    Those I've found seems to have about 50 lines of code just to load a file and add through a complex for a beginner.

    Thank you very much

    I suggest you save the data loaded in a variable that can be linked, then bind the properties of the text - who:

    [Bindable]

    var myXML:XML;

    public void dsSetup(event:MouseEvent):void

    {

    myXML = new XML (myLoader.data);

    currentState = "MainMenu";

    }

    ...

  • Need help to retrieve the magnetic border

    As the title says, I need help to get the magnetic border thing (I don't know what his name). It helps a lot when I am rearraging my dekstop icon so that they are all neatly. Its the sticky feeling when you put an icon next to each other. I installed Stardock Fences before and which could lead to the missing or disabled?

    Hello

    • Right-click on an empty part of the desktop
    • Leave the mouse on the view
    • Click Align icons on the grid

    Tricky

  • Need help to retrieve the Satellite Pro C850 - 1 k 3

    Hello

    I'm new to this forum, but I really need someone's help that my laptop has had a virus on it, and I have to do a complete uninstall of windows 8, (it was preinstalled, so I don't have a restore disc)

    Every time I try to uninstall windows it says that some files are missing and to insert a disc of recovery of some sort that I did not.

    How can I do this?

    Thanks in advance for assistance.
    PS: I tried to create a recovery with a blank dvd disk but it says insert USB pen, I did not.

    > I tried to create a recovery with a blank dvd disk but it says USB pen insert, I did not.
    Usually, you can choose between USB flash memory and the DVD disc.
    Did you change this option before trying to create the recovery media?

    > When I try to uninstall windows it says that some files are missing and insert a disc of recovery of some sort that I did not.

    I have no idea what you tried to do, but the fact is that if you want to retrieve the laptop, you must use either the Toshiba recovery media (USB key or DVD disc) or recovery of HARD drive option, you can try:
    More details [here: http://aps2.toshiba-tro.de/kb0/TSB2A03ES0000R01.htm]

  • need help on deleting the recent files in photoshop on Mac.

    When you start up of photoshop and your in the start screen where it shows all your files, how to remove the file from this screen. I can remove them from my finder section where it shows all the documents and files and downloads, but it will not remove them from the recent files in photoshop. I need to clean my files please help.need

    Hi charlienelson,

    Please follow the steps below.

    > Launch Photoshop

    > Click on file > open recent > clear recent files list

    > Restart Photoshop and check for the issue.

    Let me know if it helps.

    ~ UL

  • I need help to retrieve the windows defender in my cpu

    Some time ago, I had spyware doctor™ as my antivirus program, it seems somehow I deleted windows Defender, yesterday, I received a messagein my cpu "expired" so I've updated but still does not work, I checked in the Security Center and he showed me a white page that says windows defender;" but I can't open the cause my processor cannot find this program... How can I get it back? I followed the solution that microsoft it but still does not... u can help me please? Oh, it shows the error code is not if safe on the last digit 80070008 im...

    Again I want to thank you for your help and for having the patience again, I followed the steps you recommended. I typed services.msc in Start menu and when I found the winddefend service, is not specified if is automatic or manual startup type, there empty, when I double click on it, it showed me the following message:
                                                                                     the system cannot find the specified file
                                                                                     
    but there is a startup message blue on the left upper side of the service window, when I click on it to start after a few seconds of download (2 or 3), he has shown the following message:
                                                                                    Windows failed to start service on the local computer winddefend
    error 126: the specified module could not be found
    I don't know what else to do, can u please help me with this once more? I don't want to be a pain in the neck, but I really want to fix this processor. do I have to erase everything on my cpu and restart everywhere? He could return to the original values?, Oh another thing... when I click on the icon to vote useful how support is... I click it is only cero and 1 options or there are higher scores? If yes tell me how I mark your top help... I hope I hear from you soon... and once again thank you for the time spend you in my problem Mr. Ajay K.

  • Need help to retrieve the password for user account Windows 8.

    I need help!

    I have configured my windows 8 "admin" or "user account" password for over a year now and I don't remember what it is. I tried to download a new antivirus on the computer software but it takes the administrators password to make changes to this laptop.

    How can I know what is this password and how do I solve the problem in order to be able to install new software?

    Thanks in advance

    Josh

    Hello

    "What to do if you forget your password Windows 8/8.1"

    http://Windows.Microsoft.com/en-us/Windows/what-do-forget-Windows-password#1TC=Windows-8

    If you have forgotten your Windows password, there are several ways to recover or reset:

    • If your PC is on a domain, your system administrator must reset your password.

    • If you use a Microsoft account, you can reset your password online. For more information, see the Web to reset your password page.

    • If you use a local account, use your index of password as a reminder.

    If you've tried these suggestions and still unable to connect:

    • If you have Windows 8.1, you will need to reinstall Windows.

    • If you have Windows RT 8.1, you will need to contact the manufacturer of your PC.

    @@@@@@@@@@@@@@@@@@@@@@@@@@@@@

    Microsoft prohibits any help given in these Forums for you help bypass or "crack" passwords lost or forgotten.

    Here's information from Microsoft, explaining that the policy:

    http://answers.Microsoft.com/en-us/Windows/Forum/Windows_7-security/keeping-passwords-secure-Microsoft-policy-on/39f56ef0-5d68-41AD-9daa-6e6019c25d37

    See you soon.

  • Need help to retrieve the Satellite L755 - 16 c

    My laptop Toshiba Satellite L755 - 16 c, have system image to recover in original configuration, its does not work now, when you try to run it, a pop window shows that window cant restart in Windows recovery environment to complete the recovery operation. I tried with the DVD I created before also now not working is not with it, the same message coming from recovery.

    I tried to create a new recovery media recovery media creator by a pop window shows only "window looking TRMCLchr.exe cant find, which may changed or moved.

    Please help me solve the problem to return the laptop to original configuration

    Originally posted by Francis B Payyappiilly
    ... When you try to run it, a pop window shows this window can not restart in Windows recovery environment to complete the recovery operation. I tried with the DVD I created before also now not working is not with it, the same message coming from recovery.

    Hello

    This is all a bit confusing to me. If you have created a recovery media in the past, you should be able to reinstall the recovery image using this media.
    To be honest I don't understand exactly what is happening and what message is displayed on the screen.
    Can you please write what you can see on the screen? Message description full please.

    Start your laptop and enter the BIOS. By default the BIOS settings and restart your machine. Press F12 at first upward and choose the boot for your recovery media device and start the installation with ENTER.

    Please describe exactly what happens when you do this.

  • Problems with codec... need help to open the video file...

    Hello
     
    I tried the previous suggestions and ran the reset... no change...

    · What happens when you try to play the video file? You get the error message? Yes, error msg - windows media player cannot play the file. The player might not support the file type or does not support the codec used to compress the file.
    · What is the file format? 3GPP
    · The question is limited to this video file? Yes, all the videos copied from my cell and downloaded on PC, the problem occurs. Note all the copied images have no problems.
    · Did you do changes on the computer before the show? None.

    Any further suggestions? I fear, if I should try a codec download from the internet and that you and the measures to be taken.
    Thank you
    Dan
    ... Any further suggestions? I fear, if I should try a codec download from the internet and that you and the measures to take...

    I would recommend that you download and install K-Lite Codec pack from here.


    Download K-Lite Codec Pack

    Get either the Standard or complete package to halfway to the bottom of the page. There is a package tailor-made for 64-bit if your Windows 7 is that the flavor. The 64-bit package is not always necessary, as most of the programs are still 32-bit.

  • Need help to retrieve the value of an xml tag.

    Hi all

    Hello all, I have problem to extract a value from an xml tag. I created an xml schema based on the schema, I created an xmltype table and inserted a value to the table. When I try to extract a value of a particular tag I can't do... Kindly help me to solve this problem. Here by I write all working, I did...

    I use the following client:
    -----------------------------------

    SQL * more: Release 10.2.0.1.0 - Production on Mon 31 Jan 11:44: 59 2011

    Copyright (c) 1982, 2005, Oracle. All rights reserved.


    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With partitioning, OLAP and Data Mining options


    ////////////////////////////////// XML Schema ///////////////////////

    Start
    () dbms_xmlschema.registerSchema
    "http://www.oradev.com/chipsxml.xsd,"
    ' < scheme xmlns = "http://www.w3.org/2001/XMLSchema".
    targetNamespace = "http://www.oradev.com/chipsxml.xsd."
    xmlns:SAMP = "http://www.oradev.com/chipsxml.xsd".
    version = "1.0" >

    < feature name = 'Field1' >
    < complexType >
    <>sequence
    < element name = "UTI" >
    < complexType >
    <>sequence
    < element name = "U01" type = "string" / >
    < element name = "U02" type = "string" / >
    < element name = "U03" type = "string" / >
    < element name = "U03a" type = "string" / >
    < element name = "U03b" type = "string" / >
    < element name = "U03c" type = "string" / >
    < element name = "U04" type = "string" / >
    < element name = "U05" type = "string" / >
    < / sequence >
    < / complexType >
    < / item >
    < / sequence >
    < / complexType >
    < / item >
    < / schema > ',
    (TRUE, TRUE, FALSE, FALSE);
    end;


    A table that has several column.

    CREATE TABLE chipsxmltable1)
    Identification number, XMLDATA XmlType)
    XMLTYPE XMLDATA STORE AS OBJECT / RELATIONAL
    XMLSCHEMA 'http://www.oradev.com/chipsxml.xsd '.
    ELEMENT 'field1 ';


    Insert the query in chipsxmltable.

    INSERT INTO (VALUES) chipsxmltable
    XmlType.CreateXml ("<?") XML version = "1.0"? >
    < xmlns:samp samp: field1 = "http://www.oradev.com/chipsxml.xsd" >
    < USE >
    No. < U01 > < / U01 >
    Y < U02 > < / U02 >
    Y < U03 > < / U03 >
    < U03a > Y < / U03a >
    < U03b > Y < / U03b >
    < U03c > Y < / U03c >
    Y < U04 > < / U04 >
    Y < U05 > < / U05 >
    < / UTI >
    ((< / samp: field1 > '));


    To display the data in a field with the structure:
    --------------------------------------------

    1. motion:
    ----------
    Select * from chipsxmltable1;

    Output:
    -------


    ID XMLDATA
    ---------- -----------------------------------------------------------------
    1 <? XML version = "1.0"? >
    < xmlns:samp samp: field1 = "http://www.oradev.com/chipsxml.xsd" >
    < USE >
    No. < U01 > < / U01 >
    No. < U02 > < / U02 >
    Y < U03 > < / U03 >
    < U03a > Y < / U03a >
    < U03b > Y < / U03b >
    < U03c > Y < / U03c >
    Y < U04 > < / U04 >
    Y < U05 > < / U05 >
    < / UTI >
    < / samp: field1 >


    2 query: (both the query shows the same result)
    ----------

    SELECT X.xmldata.getClobVal ('XMLDATA' FROM chipsxmltable1 X);

    Select extract (XMLDATA, "/ Field1'") .getstringval ("XMLDATA" chipsxmltable1 x);


    Output:
    --------

    XMLDATA
    -----------------------------------------------------------------
    <? XML version = "1.0"? >
    < xmlns:samp samp: field1 = "http://www.oradev.com/chipsxml.xsd" >
    < USE >
    No. < U01 > < / U01 >
    No. < U02 > < / U02 >
    Y < U03 > < / U03 >
    < U03a > Y < / U03a >
    < U03b > Y < / U03b >
    < U03c > Y < / U03c >
    Y < U04 > < / U04 >
    Y < U05 > < / U05 >
    < / UTI >
    < / samp: field1 >


    To display the data as a single string without structure using "getstringval()":
    ---------------------------------------------------------------------------------

    3 query
    ---------

    Select extract (XMLDATA, "//text()').getstringval()"CHIPS - XML"of chipsxmltable1 x;)

    Output:
    -------

    CHIPS - XML
    ---------------------
    NoNoYYYYYY


    To display the data as a single string without structure using "getclobval()":
    ---------------------------------------------------------------------------------

    4 query
    -------

    Select extract (XMLDATA, "//text()').getClobVal()"CHIPS - XML"of chipsxmltable1 x;)

    Output:
    --------

    CHIPS - XML
    -----------------
    NoNoYYYYYY


    To display the data in a tag with or without structure (which does work) using the function "EXTRACT":
    -------------------------------------------------------------------------------------------------------------

    6.query:
    ---------

    Select extract (XMLDATA, "/Field1/text()').getstringval()"XMLDATA' chipsxmltable1 x;

    Select extract (XMLDATA, "/Field1/UTI').getstringval()"XMLDATA' chipsxmltable1 x;

    Select extract (XMLDATA, "/Field1/UTI/U01').getstringval()"XMLDATA' chipsxmltable1 x;

    Select extract (XMLDATA, "/Field1/UTI/U01/text()').getstringval()"XMLDATA' chipsxmltable1 x;


    Output:
    --------

    CHIPS - XML
    ---------------------------------------



    The queries above are not fetch the value.



    To display the data in a tag with or without structure (which does work) using the function "EXTRACTVALUE":
    ------------------------------------------------------------------------------------------------------------------

    7 query:
    ----------

    Select extractValue (XMLDATA, ' / Field1/UTI ') 'XMLDATA' of chipsxmltable1 x;

    Select extractValue (XMLDATA, ' / U01/UTI/Field1 ') 'XMLDATA' of chipsxmltable1 x;


    Output:
    --------

    X
    -



    The queries above are not fetch the value.


    My question is:
    --------------------
    How to extract the values of xml tag when the value are inserted through xml schema?


    My apologies if the description is not clear. Kindly let me know if further details are required. Thanks a lot for your help.

    Very cordially,
    Godwin Castro C.V.

    Hello

    You must declare the namespace of each element used in the XPath expression, like this:

    SQL> select extractvalue( XMLDATA
      2                     , '/samp:Field1/UTI/U01'
      3                     , 'xmlns:samp="http://www.oradev.com/chipsxml.xsd"' ) "XMLDATA"
      4  from chipsxmltable1 x
      5  ;
    
    XMLDATA
    --------------------------------------------------------------------------------
    No
     
    
    SQL> select extract( XMLDATA
      2                , '/samp:Field1/UTI'
      3                , 'xmlns:samp="http://www.oradev.com/chipsxml.xsd"'
      4                ).getstringval() "XMLDATA"
      5  from chipsxmltable1 x
      6  ;
    
    XMLDATA
    --------------------------------------------------------------------------------
    
      No
      Y
      Y
      Y
      Y
      Y
      Y
      Y
    
     
    

    Please see EXTRACT and EXTRACTVALUE documentation:
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14200/functions051.htm#i1006712
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14200/functions052.htm#SQLRF06173

    BTW, 'XMLDATA' is a pseudo-column used by Oracle. I don't know if it will never cause any conflict, but perhaps you need to rename your column.
    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14200/pseudocolumns010.htm#SQLRF00256

    Kind regards.

  • Need help to reset the associated file.

    Original title: DLL Microsoft Deprecated components - I need to re - setup my default return records!

    I put my. LNK and a few other files to open in realplayer video player! I thought all the files I was looking at were for media - they were not!   How can I re set my files to what they were! I already totally uninstalled Realplayer from Realplayer.com and restarted the computer, in the hope that could FORCE a reset!   as you can tell, I am not very tech-savvy, - please help!

    Right click on a file of a given type and then go to properties and click change and then set the program you want to open the file with.
     
    Steve
     

    I put my. LNK and a few other files to open in realplayer video player! I thought all the files I was looking at were for media - they were not!   How can I re set my files to what they were! I already totally uninstalled Realplayer from Realplayer.com and restarted the computer, in the hope that could FORCE a reset!   as you can tell, I am not very tech-savvy, - please help!

  • Need help to retrieve the Satellite L750

    Hello

    My laptop fell to the ground. HARD drive has been damaged. Not bootable.

    I could only recover file recovery disk HARD of L: (recovery partition). Because a copy of the record of recovery disk on another PC and the HARD drive was completely unreadable

    I have no recovery discs.

    How can I recover the folder HDDrecovery BONES? (Already bought new HARD drive)

    Thanks for your help

    Hello

    Unfortunately, you cannot start file recovery image installation. It works a little different.
    What you can try is to read http://aps2.toshiba-tro.de/kb0/HTD4103KB0000R01.htm and check if you can somehow create recovery media follows instructions described here.

  • Need help to parse the xml string to populate the drop-down list

    Here is my: problem

    I have a hidden text field that contains the text of an xml

    <>facilities
    < building >
    < name > Building A < / name >
    < name > building B < / name >
    < name > building C < / name >
    < name > building D < / name >
    < name > building E < / name >
    < name > building F < / name >
    < name > building G < / name >
    < name > building H < / name >
    < / build >
    < / facilities >

    My goal is to read this with JavaScript xml string to populate a drop-down list with values of element (name). Does anyone know how script that?

    Attached is a sample .xdp

    See you soon,.

    Jesse

    Here is an example of change. I put the code click on the button, so you can see it in operation... You can place this code in the event that makes sense for you. I also added another field to show the DOM (this is for debugging purposes and you can remove this field if you want).

    Paul

  • load the xml file into a database to help table of travel point

    Hello

    Someone help me please with a possible approach. I have an interface for APEX users where users can download a file xml in apex table wwv_flow_files using the element to browse with a button "submit". Now, after loading the xml file in the wwv_flow_files table. I need to read and load the xml data into a table sample_tbl. I'm using the version of Oracle APEX 4.0 and Oracle 10 g R2 database. Here is an example of XML file to load. Please help me possible suggestions.

    <? XML version = "1.0" encoding = "UTF-8"? >

    < dataroot generated =... >

    < MySample >

    < KeyId > 1234 < / KeyId >

    eddskc < KeyName > < / KeyName >

    < scheduleDate > 2013-06-16T 00: 00:00 < / ScheduleDate >

    < StartTime > 2013-06-16T 08: 00:00 < / StartTime >

    < EndTime > 2013-06-16T 08:30:00 < / EndTime >

    < / MySample >

    < MySample >

    < KeyId > 5678 < / KeyId >

    jppdf < KeyName > < / KeyName >

    < scheduleDate > 2013-05-19T 00: 00:00 < / ScheduleDate >

    < StartTime > 2013-05-19T 08: 00:00 < / StartTime >

    < EndTime > 2013-05-19T 08:30:00 < / EndTime >

    < / MySample >

    < / dataroot >

    Thanks in advance.

    Thank you

    Orton

    orton607 wrote:

    My sample_tbl has a start_time field and its data type DATE.

    Good.  Be sure to always store dates as the DATE.

    The application (in this case, APEX) needs to format the date date type in the appropriate human-readable format.

    The problem with the incoming data is the 't'.  You will need to convert a space using REPLACE() in the framework so that your SELECT statement

    From there on, conversion to the DATE data type is simply

    to_date( replace( start_time_str, 'T', ' '), 'YYYY-MM-DD HH24:MI:SS') as start_time
    

    And, just in case where, the conversion of DATE for the desired format:

    to_char( start_time, 'MM/DD/YYYY HH12:MI:SS AM')
    

    Although, I'm 'hours' as being left-padded with zeros... Am I looking for how / if you can get rid of the zero prefix (0).

Maybe you are looking for

  • Fan/Heatsink Assembly thermal Ribbon

    Hi, I received my fan and heatsink of heat today and inside he received instructions for the application of thermal paste with a syringe which is included in the box. As well as alcahol wipes. I don't have a syringe to dough, or wipes. Instead I got

  • Presario: I have a laptop HP Compaq Presario CQ60-224NR Notebook PC

    Hi, when I turn on my computer, I can hear it go through its connection, my wifi lite comes on but my screen remains completely black.  How can I solve this problem.  Thanks for your help.

  • HP slate 7 16 gb, how long can I give it a 1 charge?

    Looking at my manual and do not tell you how long to charge the tablet on the costs of 1st, can someone help me on this issue like this for my son and do not want the battery to garbage.

  • A "N" router will make a difference?

    I have currently a cable modem and Linksys router Linksys Wireless 'G '. I have my desktop connected via ethernet to the router port, and I use the wireless router for an Acer laptop and a ROKU box, watch NetFlix streaming videos.  As much as I fear,

  • How to get rid of the message 8024002d insert the Microsoft works 9.0.msi disc

    I have an Inspiron 1564 with Windows 7 that he had loaded Microsoft when I bought it. I received an error 8024002D, who tells me to insert discmicrosoft works 9.0.msi I did fi this error I have not had no disk how can I get rid of him?