How to add tags in the existing XML file?

Hello
I have a requirement in which I need to add a tag to the existing xml data.

For example:
< ROW >
< EVNT_ID > 7333976 < / EVNT_ID >
< DISTRCT_CD > 67 < / DISTRCT_CD >
< TIME_OFF > 6 May 2008 10:50:04 < / TIME_OFF >
< / ROW >

The desired output is,

< DI_DATA >
< ROW >
< EVNT_ID > 7333976 < / EVNT_ID >
< DISTRCT_CD > 67 < / DISTRCT_CD >
< TIME_OFF > 6 May 2008 10:50:04 < / TIME_OFF >
< / ROW >
< / DI_DATA >

I must add < DI_DATA > < / DI_DATA > at the beginning and end of the entry.

Anyone of you could help me with that?

Thank you
GV

If your XML is just in a CLOB, you can just use manipulation of strings to add/add nodes on. If you have it in an XMLType you could just do the following

select appendchildxml(XMLTYPE(''),
                              'DI_DATA',
                              XMLTYPE('
7333976
67
06-May-2008 10:50:04 AM
'))  -- this would be your variable
  from dual;

which will put your data in the DI_DATA node.

Tags: Database

Similar Questions

  • How to add lines to the PresetEffects.xml from a script

    Hi, I would like to add a few lines in the PresetEffects.xml to another text file or an another JavaScript add lines like this how can I do? :

    < name of the group = "$$$ / AE/Preset/AnimalHead14 / = mouth" >

    < name of the cursor = "' $$$ / AE/Preset/AnimalHead14/MouthOffsetX = mouth X shift" default = '0' valid_min = '-30,000"valid_max ="30000"slider_min = slider_max"-500"= '500' precision ="1"DISPLAY_PERCENT ="true"/ >"

    < name of the cursor = "' $$$ / AE/Preset/AnimalHead14/MouthOffsetY = mouth Offset Y" default = "0" valid_min = "-30,000" valid_max = "30000" slider_min = slider_max "-500" = '500' precision = "1" DISPLAY_PERCENT = "true" / > "

    < name of the cursor = "' $$$ / AE/Preset/AnimalHead14/MouthScaleWidth = scale Overture" default = "100" valid_min = "-30,000" valid_max = "30000" slider_min = slider_max '-500' = '500' precision = "1" DISPLAY_PERCENT = "true" / > "

    < name of the cursor = "' $$$ / AE/Preset/AnimalHead14/MouthScaleHeight = scale of mouth height" default = "100" valid_min = "-30,000" valid_max = "30000" slider_min = "-500" slider_max = "500" precision = "1" DISPLAY_PERCENT = "true" / > "

    < / Group >

    < / effect >

    {function onClick.btn

    Add the lines of my text file in the PresetEffects.xml

    I did once, like this:

    var scriptEffect = {};
    scriptEffect.xml =
    
        
            
            
        
        
            
            
            
        
    ;
    scriptEffect.matchName = [email protected]();
    
    function installScriptEffect(){
    
        var ret;
        var file = new File(Folder.appPackage.absoluteURI + "/PresetEffects.xml");
        var str, idx, header, xml;
        var xmlSettings = XML.settings();
    
        XML.setSettings(XML.defaultSettings());
    
        try{
            if (!file.exists) throw "ERR_FILE_NOT_FOUND";
    
            file.open("r");
            str = file.read();
            file.close();
    
            idx = str.indexOf("");
            if (idx<0) throw "???";
    
            header = str.substring(0, idx-1);
            xml = new XML(str.substring(idx, str.length));
    
            if (!xml.contains(scriptEffect.xml)){
                xml.appendChild(scriptEffect.xml);
                if (!file.copy(new File(file.absoluteURI+".bak"))) throw "ERR_CANNOT_WRITE";
                file.open("w");
                if (!file.write(header + xml.toXMLString())) {file.close(); throw "ERR_WRITE_FAILED";};
                file.close();
                alert("Preset installed succesfully. Please restart After Effects");
                }
            else{
                alert("Preset already installed. You need to restart After Effects to make it effective.");
                };
            ret = true;
            }
        catch(e){
            file.close();
            alert(e);
            ret = false;
            };
    
        XML.setSettings(xmlSettings);
    
        return ret;
        };
    

    Then, when you want to add the effect, check with myLayer.effect.canAddProperty (scriptEffect.matchName).

    If true, nothing to do, otherwise use the installScriptEffect function. Normally, it works (haven't tried for a long time).

    Xavier

  • How to add anchor in the existing menu widget

    Does anyone know how to add an anchor point to a button on the menu widget?

    When I click on one of the buttons in the menu widget... will NOT only link hyperlink... options do not get me a link to an anchor.

    Why? How? Laughing out loud

    any help is appreciated?

    You should be able to do if you set your menu on manual. You will need to create the entire menu from scratch, but you will have more control over the links.

  • How to create the existing XML file bar chart

    Hi all

    I'm new to flex, I need your help to develop a flex during approx. dashboard we file sample.xml. using what I have to create a bar chart or a pie chart.

    Please help me

    The XML looks like this...

    <? XML version = "1.0" encoding = "utf-8"? >
    < user name = "123412343" >
    < name >
    < name > these < / lastName >
    Vijay < firstName > < / name >
    < / fullName >
    < Preferences >
    < modWidth > 235 < / modWidth >
    < modHeight > 250 < / modHeight >
    < > 1650 totalWidth < / totalWidth >
    < > 1650 totalHeight < / totalHeight >
    < modsX > 4 < / modsX >
    < modsY > 2 < / modsY >
    < / Preferences >
    < id module = "Status2" >
    < fenetreouvrir > true < / fenetreouvrir >
    < pointsToShow >
    < label p = 'Proposals' / >
    < label p = "Project" / >
    < label p = "DEP Ptba" / >
    < label p = "EPA Ptba" / >
    < / pointsToShow >
    < dataSetsToShow >
    < label > 2006 < / label >
    < label > 2007 < / label >
    < / dataSetsToShow >
    < / module >
    < / user >

    convert this ArrayCollection collection called chartData xml file

    var charOption:String = 'totalHeight '; / Use this to set the yField property...



    <>
    dataProvider = "{chartData}.
    categoryField = "time" / >






  • How to add captions to the existing slide show in iphoto?

    How can I add captions to my slide show photos in iphoto?

    Slideshow already exists, I just want to add captions... I find no "add text" or settings and I don't see any 'touch gear' either.  Help?

    What version of iPhoto? The operating system?

  • How to add data to the SD card file?

    I use OutputStream to write data to a file on the sd card.

    Before you start coding, I assumed that we can use a similar api seek() but I couldn't find a way to move the file position.

    is it possible to add data using OutputStream or any other method?

    FileConnection.openOutputStream (long byteOffset)

    byteOffset - number of bytes to skip from the beginning of the file when the positioning of beginning of the OutputStream. If the supplied offset is greater than or equal to the current size of the file, the OutputStream is positioned at the end of the file to be added.

  • How do you use the config.xml file to determine which version of an application, a user will download?

    I have two APKs for the same application and I implemented the config.XML of lower version number working for all screen sizes.  The config.XML for the higher version number is set up for only the scresns large and extra-large.  Here's the code from the config.xml file.

    Version 1

    < media screens android: anyDensity = "true" android: Center = 'true '.
    Android: smallScreens = "true".
    Android: normalScreens = 'true '.
    Android: largeScreens = "true".
    Android: xlargeScreens = "true" / >

    Version 2

    < media screens android: anyDensity = "true" android: Center = 'true '.
    Android: smallScreens = "false".
    Android: normalScreens = "false".
    Android: largeScreens = "true".
    Android: xlargeScreens = "true" / >

    When I try to download the app on Google game, only the top version is available, regardless of the size of the unit.  When I asked Google game why this was not behave as expected, they said that the file manifest for both applications is the same.  Here is the code, they shot in the manifest after having used PhoneGap Build.

    < media screens android: anyDensity = "true" android: smallScreens = "true" android: normalScreens = "true" android: largeScreens = "true" android: Center = "true" android: xlargeScreens = "true" / >

    Can someone explain why PhoneGap Build is not using the settings I set in the config.xml file?  And how to fix this?

    The tag is not a valid tag in the config.xml file. This is probably why you see the same tag in two, as the build service is ignorant.

    As to how solve you this problem. Currently, you can not, but the next version of android-cordova will include the ability to add a tag which you will be able to use like this:

  • How to add text to the file selected?

    I have already updated title but I don't know how to add it to the selected real file (the one in the middle)... I read on some other forums but its still confuse me.  Also, is there anyway to add the effect of movement, as drag in or dissolve almost?

    Screen Shot 2016-02-19 at 10.27.40 PM.png

    I mean this in the nicest way possible, but it's very wacky workspace you put in place there. Create titles is muuuuch easier in the standard workspace Edition. When you create / open a title in the editing workspace, he creates a floating large window with the title of all the members of panels. It is about the only time I am ok with windows in the first floating. You will create the title in the window title, and then close the window title entirely. The video for the title will then be in your project Panel (which you can not common to see in your current workspace configuration, but will be very apparent in the workspace standard edition in the lower left). So the best thing to do is to simply drag the title element of the project to sequence Panel (another Panel today, you don't see in your current workspace arrangement.

  • Modify the config.xml file (what is the command to save)?

    Hello

    I use ESXi 4.1. I am connected to the host via SSH and Putty.

    I need to add something in the config.xml file however I can't save changes to it.

    I am connected to/etc/vmware/hostd #vi config.xml

    When I add a line and try to save it is not. How save you changes to a file? I tried Ctrl X, S, Z

    Thank you guys.

    (+)

    : wq means you need to swich mode command by esc. Also take a look at Vi Cheat Sheet

  • How can I trigger "Add tags to the document" via JavaScript?

    How can I trigger "Add tags to the document" via JavaScript? I am trying to add this fuction ITextSharp if when the user opens the pdf it could mark the document once it is opened automatically

    Is not possible.

  • How to add contacts to your existing groups or how to manage your groups?

    Anyone know how to add contacts to your existing groups or how you manage your existing groups. How do you even add new groups I can't find a way to do this in the ocntacts.

    Hello

    1. what version of Windows is installed on the computer?

    2 are. what groups you referring?

    3. What mail client do you use?

    If you use Hotmail, you can post your request in the Windows Live Forum.

     

    http://answers.Microsoft.com/en-us/windowslive/Forum/Hotmail

    You can check the link:

    http://Windows.Microsoft.com/en-us/Windows-Live/Mail-import-backup-restore

     

    Please get back to us with the above information so that we can help you accordingly.

  • How to add tags to shirts

    Is it possible to add tags to the files? I know how to add office document files, but I would like to add keywords/tags in files.

    No you can't mark folders.

  • How to add programs to the start of the file using Vista

    How to add programs to the start of the file using Vista

    Hi Harry,.

    Oddly enough, you can actually do it in msconfig except if it is already there and simply not checked as opposed to not being do not at all (although you would think that they would understand this option).

    The easiest way is to add the program (or a shortcut to the program) in the folder all Menu Programs Startup.   Here is the procedure: http://www.ehow.com/how_5098465_add-startup-programs.html.  Remember, to do this, you must either a shortcut existing (perhaps on the desktop or elsewhere in the menu all programs) or you need to find the source file (probably somewhere in C:\Program Files depending on what you want to add) and either copy it and add it to the startup folder or right-click on it and create a shortcut to copy into the startup folder.  Once you reboot, this program starts during the initial commissioning process and you will now be able to control using msconfig.exe, if you wish.

    Another option is to do this by using the registry editor.  If you decide to try this, first create a restore AND system restoration point backup of the registry before you begin.  Here is the procedure: http://www.ehow.com/how_7304438_add-program-msconfig-regedit.html.  I recommend to use this ONLY if the previous procedure does not work for some reason any as long as that the procedure is simpler and safer.

    If you want a simpler way to manage and control startup programs, you can try it free WinPatrol http://www.winpatrol.com/download.html that change monitors for startup programs if you set it to run in real-time so that you know when to try new programs are added to your Start menu and, for the purposes of this question includes an Add button which opens a link to a window of Windows Explorer where you can browse the program you want to add, click open to select and then add it directly to the commissioning.  If you prefer it does not work all the time, you can simply uncheck the box which includes this program and it will work only when you choose to run (but at the start, will work as an indication otherwise or configured).  It will appear not in the start menu in all programs (Finally, WinPatrol is, but not programs, it adds to the start), but it will appear in WinPatrol (which also lets you manage what you want or not start with checkboxes as in msconfig) and sure in msconfig - but only after a reboot is complete the process of adding.

    I hope this helps.  Personally, I use WinPatrol myself and let it run in real time.  Since I do a lot of installations, it helped me often prevent the addition of a startup item I haven't really need and reduces how many times I actually need to check what is happening out there.

    If this answers your question without the need to repost in another forum, please mark it as an answer.  If this isn't the case, then of course you must republish as suggested above.

    Good luck!

  • Add tags for the documents tool put an object behind the other or just the contents of page deletions?

    Using Acrobat Pro XI to make PDF documents compatible 508. I had a number of questions went using Add Tags to the document option, it is one object behind the other or remove them all together. Also had problems when you try to adjust the reading direction, content is moved or deleted. This PDF file is created from InDesing CS5

    Someone knows what I'm talking about or have any ideas on how to fix it? Thank you

    Content should always be deleted by adding tags, but it can appear so because - as you note - objects can hide behind other objects. In theory, you can bring out them of hiding to rearrange things in the part of the order, but I have much more luck using the content pane - it provides a level of much finer control. If the text is hidden behind a shaded box, for example, I'll move the box over the text in the content order, then usually convert the box to an artifact if it is already.

    I hope this helps.

    a 'C' student

  • Add selection to the existing mask

    Thissi is maybe somwhere mentioned in the manual, but I could not find.

    You created a layer mask with selected objects, finished edge it - fine

    All selections (ants in market) are now removed from the image

    So you see you must add more stuff to the mask, if you select the new odjects

    But how do you * add them * to the existing mask? Is there a quick way to do a single click?

    Select items and apply whatever you need improvements. Hold down SHIFT and Ctrl (PC) or Cmd (Mac) and click on the thumbnail of the mask. This will add the new selections and selections of original mask together. You can now fill with black or white on the layer mask.

Maybe you are looking for

  • Satellite A205 S4797 - can not find the drivers for my player

    I have recovery disks and the Windows Vista installation disc. When I try to install error meesage says that it cannot find the drivers for my player.I tried scannong CD player and there are not 32-bit, 64-bit, all them have different drivers and if

  • Satellite A300 - cannot install XP drivers

    Hello. I just reinstalled my laptop. I tried to install the display driver, but the pc response was "your computer don't not satisfying the minimum requirements. It is the same for a few other drivers. In addition, everything that I try to open Xp ru

  • Can someone tell me how to change the language on the sidebar?

    Hello world.  Can someone tell me how to change the language on the sidebar.  I'm in a language other than English, and it drives me crazy.  Thanks, have a nice day.

  • Photosmart C4795: No printing on paper of the Document

    This morning, I tried to print a black and white word document and the printer spits out just the white sheet of paper I. I assumed that the ink was out so I replaced both cartridges with new ones. Initially, the small screen on the printer told me t

  • Office XP will always work in W7?

    I get a new computer with W7... will be MS office to work always WXP? And any other MS work program with 7? Concerning Ian