DDX XML out help

Hey everyone quick question that I hope someone can help me
out with. We are currently in the process of making a switch from
our old CMS to websphere and we have a few thousand PDF documents
that have hard coded links in them.
Anyhow I was thinking I might be able to use DDX with CF8 to
extract the doc info in XML then use CFDocument to recompile them
back again but change the links to be a different URL.
I have been able to get the XML out with DDX but its not
retaing the formatting in the xml or the link information.
So I guess my question is, is this possible with DDX?
I also some some people talking about a open source solution
called PDFBox, but its all java and I'm not a java expert, but if
anyone knows of some tutorials or examples of using this with CF
that would be awesome.
Thanks for any help
Mike.

Yes, but the way you do this will depend on the tool you use. For instance when using Axis refer to:
http://wiki.apache.org/ws/FrontPage/Axis/AxisClientConfiguration/ViewSOAPMessages

Similar Messages

  • I put the CD or DVD in my iMac it stay for a while then it comes back out help please

    I put the CD or DVD in my iMac it stay for a while then it comes back out help please

    Akay3,
    Please remember we are not there to see so you have to be much more descriptive. Please complete your profile and indicate which version of OS X is installed, what iMac you own and exactly what CD and/or DVD you are referring to so we have some basic clues.

  • HT201303 Iv tired everything to change my serIcuty passwords and I can't I don't remember even filling them out HELP!!!

    Iv tired everything to change my serIcuty passwords and I can't I don't remember even filling them out HELP!!!

    Welcome to the Apple Community.
    Contact Apple through iTunes Store Support

  • How can users of WebHelp print out help chapters or generate PDFs?

    More and more users of our WebHelp would like to print out help chapters or generate PDFs.
    Does anyone know if this is possible with RoboHelp10?
    I know that this function is available in Microsoft HTML Help...
    Thanks in advance.

    Theoretically it is possible with Microsoft HTML help. Try it though and you will see the output is pretty horrible.
    The only solution I have seen is for you to generate that output and then provide a link to the PDFs.
    See www.grainge.org for RoboHelp and Authoring tips
    @petergrainge

  • I tried to update to IOS 5, but it said my connection timed out .Help!on timed out.

    i tried to update, but it said the connection timed out. help!

    Disable or turn off all firewall and anti-virus software and try the download again.
    Stedman

  • Reg: XML PUBLISHER HELP

    Hi all,
    I am building report using xml publisher. Problem i facing was ,
    1. I created the template in RTF and attached to data definition
    for eg: my rtf is
    sno item quantity price ( I created this field in table structure and mapped to xml data)
    Total Price ( this also i am getting from data definition)
    The below is sample constant sentence for my client and typed just below Total Price ( field i mentioned above)
    Inspected By Approved By
    1)
    ________________________________ 1)________________________________ Store Incharge : ______________________
    2)
    ________________________________ 2) ________________________________ Received : _______________________
    3)
    ________________________________ 3 ________________________________ Prepared By : _______________________
    NOTE : ABOVE MENTIONED LINES ARE CONSTANT ONE.
    2. When i ran the report, if my data definition return 5 lines means , i am getting PDF output Correctly in single page (1st page)
    3) If my data definition returns lines more than 8 lines means, I am getting PDF output with Table structure values with item, in 1 st page and Constant sentence in 2nd page of PDF
    4) If my data definition returns lines between 5 and 8 means, I am getting PDf output with table structure values with item and some of Constant sentence of my client in 1 st page and few of the constanst sentence in 2nd page.
    Actually my need
    Even if the data definitions exceeds more than 5 lines the constant sentence should be placed either in the first page or in the next page based on the no. of lines in the data definition.
    How to resolve this... any approach most welcome. Wat changes i have to make.

    Hi Shruti,
    You can start with the BI publisher page on OTN http://www.oracle.com/technology/products/xml-publisher/index.html.
    Check out the tutorials (Oracle by Example). There's lot of good information out there. Check out the BI publisher guide here:http://www.oracle.com/technology/products/xml-publisher/xmlpdocs.html
    Search the forum or post questions about any specific questions you may have about formatting numbers and dates.
    Hope this helps.
    Thanks!

  • XML Publisher Help

    Hi,
    We currently have a payslip report that has been developed using Oracle reports, but for this to run we have to change our NLS_LANG setting from UTF8 to WE8ISO8859P1.
    The problem with this is to apply patches Oracle have told us we need to have the NLS_LANG set to UTF8.
    As a result Oracle have said that:
    The only available workaround for generating PDF on a UTF8 character set instance is to install and utilize the XML Publisher product or upgrade to E-Business Suite to Release 12.
    We don't have any plans to upgrade to Release 12, so I am looking to use XML Publisher. I have a couple of questions:
    Is this an add-on?
    Where is the best place to obtain navigation guides and tutorials to teach myself this?
    I have had a look at some of the pre-defined templates already and I am not sure how to create my own rtf file so that my required fields are passed to the template.
    Any help would be greatly appreciated
    Many Thanks
    Martin

    Hi Shruti,
    You can start with the BI publisher page on OTN http://www.oracle.com/technology/products/xml-publisher/index.html.
    Check out the tutorials (Oracle by Example). There's lot of good information out there. Check out the BI publisher guide here:http://www.oracle.com/technology/products/xml-publisher/xmlpdocs.html
    Search the forum or post questions about any specific questions you may have about formatting numbers and dates.
    Hope this helps.
    Thanks!

  • Error in my build.xml file (help with spotting syntax error requested)

    Hi
    I have written an XML file called build.xml for one of my applications. My XML editor complains that there is an error at the last line of the XML file, but I simply find it unable to correct the errror.
    It says:
    Fatal error:Build.xml[76:3-9]: End-Tag without start-tag
    The XML file itself:
    <project basedir="." default="deploy" name="concepts">
    <property name="src.dir" value="src"></property>
    <property name="build.dir" value="${basedir}/build"></property>
    <property name="build.lib" value="${build.dir}/lib"></property>
    <property name="dist.dir" value="dist"></property>
    <property name="classes.dir" value="${build.dir}/classes"></property>
    <property name="build.etc" value="${src.dir}/etc"></property>
    <property name="build.resources" value="${src.dir}/resources"></property>
    <property name="lib.dir" value="lib"></property>
    <property name="web-inf.dir" value="WEB-INF"></property>
    <property name="war.name" value="concepts"></property>
    <property file="../common.properties"></property>
    <target name="init">
    <mkdir dir="${build.dir}"></mkdir>
    <mkdir dir="${classes.dir}"></mkdir>
    <mkdir dir="${dist.dir}"></mkdir>
    </target>
    <target name="deploy" depends="clover-yes, clover-no">
    <javac srcdir="${src.dir}" destdir="${classes.dir}" classpath="${libs}" debug="off" optimize="on" deprecation="on" compiler="${compiler}">
    <include name="org/apache/commons/fileupload/**/*.java" />
    <include name="com/portalbook/portlets/**/*.java" />
    <include name="com/portalbook/portlets/content/**/*.java" />
    </javac>
    <target depends="init" name="compile">
    <javac debug="true" deprecation="true" destdir="${classes.dir}" optimize="false">
    <src>
    <pathelement location="${src.dir}"></pathelement>
    </src>
    <classpath>
    <fileset dir="${lib.dir}">
    <include name="*.jar">
    </include>
    </fileset>
    </classpath>
    </javac>
    </target>
    <target depends="compile" name="war">
    <war destfile="${dist.dir}/${war.name}.war" webxml="WEB-INF/web.xml">
    <classes dir="${classes.dir}"></classes>
    <lib dir="${lib.dir}"></lib>
    <webinf dir="${web-inf.dir}"></webinf>
    </war>
    </target>
    <!-- create the portal-concepts-lib.jar -->
    <jar jarfile="${build.lib}/concepts-lib.jar">
    <fileset dir="${classes.dir}"></fileset>
    </jar>
    <jar jarfile="${build.lib}/concepts.war" manifest="${build.etc}/concepts-war.mf">
    <fileset dir="${build.resources}/concepts-war"></fileset>
    </jar>
    <!-- concepts.ear -->
    <copy todir="${build.resources}/concepts-ear">
    <fileset dir="${build.lib}" includes="concepts.war,concepts-lib.jar"></fileset>
    </copy>
    <jar jarfile="${build.lib}/concepts.ear">
    <fileset dir="${build.resources}/concepts-ear" includes="concepts.war,concepts-lib.jar">
    </fileset>
    </jar>
    <target depends="deploy" name="explode">
    <taskdef classname="org.jboss.nukes.common.ant.Explode" classpath="${libs}" name="explode"></taskdef>
    <explode file="${build.lib}/concepts.ear" name="concepts.ear" todir="${build.lib}/exploded"></explode>
    </target>
    <target depends="war" name="all"></target>
    <target name="clean">
    <delete dir="${build.dir}">
    </delete>
    <delete dir="${dist.dir}">
    </delete>
    </target>
    </project>
    I am a little inexperienced in XML files. So I am unable to spot the error.
    I would greatly appreciate it, if some kind soul were to help me out.
    thanks a lot

    The tag
    <target name="deploy" depends="clover-yes, clover-no">...is never closed.
    close that tag:
    <target name="deploy" depends="clover-yes, clover-no">
         <javac srcdir="${src.dir}" destdir="${classes.dir}" classpath="${libs}" debug="off" optimize="on" deprecation="on" compiler="${compiler}">
              <include name="org/apache/commons/fileupload/**/*.java" />
              <include name="com/portalbook/portlets/**/*.java" />
              <include name="com/portalbook/portlets/content/**/*.java" />
         </javac>
    </target>Second error is that the depends in there (clover-yes, clover-no) are not existing as targets in your xml.

  • Methods in XML--pL help

    I have string...as
    String xstr="<?xml version=\"1.0\"?>\n"+
    "<UserGroups>\n<u_bit><![CDATA[1]]></u_bit>\n"+
    "<u_title><![CDATA[public]]></u_title>\n<u_description><![CDATA[Pages are available to all visitors - no restrictions are applied]]></u_description>\n"+
    "<u_used><![CDATA[1]]></u_used>\n<u_fromname/>\n<u_fromemail/>\n<pw_email/>\n<u_user/>\n<u_password/>\n</UserGroups>"+
    I am trying to form a xmlDoc using String Reader as follows..
    java.io.Reader reader = new java.io.StringReader(xstr);
         org.xml.sax.InputSource source = new org.xml.sax.InputSource(reader);
         org.w3c.dom.Document xmlDoc=null;
         DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
         DocumentBuilder builder = factory.newDocumentBuilder();
         xmlDoc = builder.parse(source);           
         Element xmlRoot=xmlDoc.getDocumentElement();
         Table_Name=xmlRoot.getNodeName();
         NodeList oNodeList = xmlRoot.getChildNodes();
         Node PNode=oNodeList.item(0);
         But at the end...ONodeList.item(0)...does not give anything...Am I doing anything wrong...Pl help if possible soon
    smita

    since Value is within the CDATA tag...You see a "CDATA tag", as you call it, in your XML, but the parser strips that all off and normalizes it to an ordinary string. So writing
    <![CDATA[public]]>
    is exactly the same as writing
    public
    and the parser treats them identically. So identically, in fact, that there is no way for you to find out whether CDATA was used at all.
    Sorry, that doesn't answer your actual question, but hopefully it prevents you looking in the wrong direction.

  • Flash XML file help

    I am trying to add multiple flash files to my website...the
    only way these seem to work is if the swf and corresponding xml
    file are all on the root of the website directory. I would have
    liked to organize them into files to sort.
    My problem is that many of these flash files (mainly
    purchased) have the same xml file, so I cannot use these together
    on the root. Thus, I need to either rename in the flash the xml
    file or figure out how to put into folders...please help!
    -Josh

    ANSWER: I figured it out myself. I am just replying to let
    everybody else know how I fixed it. I had the full URL in the load
    request and apparently some Flash players don't like this. I put a
    link to the file without the domain name and everybody is working
    fine. The load function, Flash, or something could not resolve the
    domian correctly and could not find the XML file. I was not getting
    a request for the file from the Flash movie so I knew it had to be
    soemthing in Flash.

  • XML Code Help

    Hey All,
    Im working towards a easier way of updating my menubar
    componet. I'm having it load from an XML file, part of the code
    works well, the other part is hosed up somewhere and thats where I
    need help I'm not sure where the issue is IM hoping someone can
    help me out. below is my code.
    The thing that has me baffeld is the first two menus work. (
    meanign everythign shows up in the menu and the links work) the
    engineering and on do not. barring form a spelling mistake.... can
    anyone see any obvious problems?

    Look at the line below:
    <link label="Creating a Card Simulation"
    url="whatever.com" icon="
    http://jsdl.jacobs.com/jpi/eng/CardBeginingImportSimEx.swf"
    icon="mov" />
    You can't have duplicate attributes in the same Node. (
    "icon" and "icon") According to the other Nodes, it looks like you
    meant to put:
    <link label="Creating a Card Simulation" url="
    http://jsdl.jacobs.com/jpi/eng/CardBeginingImportSimEx.swf"
    icon="mov" />
    You can always open the the .xml file in IE and it
    "sometimes" it gets you closer to the problem. Good Luck

  • Xml css help!

    This is a multi-part message in MIME format.
    ------=_NextPart_000_0008_01C6AB1B.755FB0F0
    Content-Type: text/plain;
    charset="iso-8859-1"
    Content-Transfer-Encoding: quoted-printable
    Yes I want to use css for this.
    I have an xml doc being pulled into my flash. Text is fine
    except =
    wherever I try to assign a style. It's also defaulting to the
    black =
    color in flash (I couldn't find a way not to select a color
    or style in =
    flash for the font) instead of the blue specified in the css
    doc. In =
    that first image/description, it cuts off at the <em>
    tag.
    Please help me understand what I'm doing wrong.
    XML doc:
    <?xml version=3D"1.0" encoding=3D"utf-8"
    standalone=3D"yes"?>
    <?xml-stylesheet type=3D"text/css"
    href=3D"xmlstyles.css"?>
    <!DOCTYPE images [
    <!ELEMENT images (#PCDATA)*>
    <!ELEMENT pic (image, thumbnails, caption, desc)>
    <!ELEMENT image (#PCDATA)*>
    <!ELEMENT thumbnails (#PCDATA)*>
    <!ELEMENT caption (#PCDATA)*>
    <!ELEMENT desc (#PCDATA)*>
    ]>
    <images>
    <pic>
    <image>images/0.jpg</image>
    <thumbnails>images/thumbs/wickham.swf</thumbnails>
    <caption>An Inspired Beginning</caption>
    <desc>Edward Virginius Valentine was born in Richmond
    in 1838. A visit =
    to the 1853 New York World's Fair with his father inspired
    him to become =
    an artist. Valentine studied in Paris and Italy from 1859 to
    1861. He =
    was granted permission to study under Berlin sculptor August
    Kiss, =
    <em>who had created the piece that first ignited
    Valentine's artistic =
    inspiration, Amazon Attacked by a Tiger.</em> In the
    spring of 1865, the =
    deaths of both Kiss and his father, Mann Valentine, led him
    to return to =
    his home in Richmond, Virginia.
    </desc>
    </pic>
    etc., etc., ...
    CSS doc: (xmlstyles.css)
    em {
    font-style: italic;
    para {=20
    font-size: 12px;
    desc {
    font-size: 12px;
    color: #0000CC;
    ------=_NextPart_000_0008_01C6AB1B.755FB0F0
    Content-Type: text/html;
    charset="iso-8859-1"
    Content-Transfer-Encoding: quoted-printable
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
    Transitional//EN">
    <HTML><HEAD>
    <META http-equiv=3DContent-Type content=3D"text/html; =
    charset=3Diso-8859-1">
    <META content=3D"MSHTML 6.00.2900.2912"
    name=3DGENERATOR>
    <STYLE></STYLE>
    </HEAD>
    <BODY>
    <DIV><FONT face=3DArial size=3D2>Yes I want to
    use css for =
    this.</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>I have an xml
    doc being pulled into my =
    flash. Text=20
    is fine except wherever I try to assign a style. It's also
    defaulting to =
    the black color in flash (I couldn't find a
    way <EM>not</EM> =
    to=20
    select a color or style in flash for the
    font) instead of the =
    blue=20
    specified in the css doc. In that first image/description, it
    cuts off =
    at the=20
    &lt;em&gt; tag.</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>Please help me
    understand what I'm =
    doing=20
    wrong.</FONT></DIV>
    <DIV><FONT face=3DArial
    size=3D2></FONT> </DIV>
    <DIV><FONT face=3DArial
    size=3D2></FONT> </DIV>
    <DIV><FONT face=3DArial
    size=3D2><STRONG>XML
    doc:</STRONG></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>&lt;?xml
    version=3D"1.0" =
    encoding=3D"utf-8"=20
    standalone=3D"yes"?&gt;<BR>&lt;?xml-stylesheet
    type=3D"text/css"=20
    href=3D"xmlstyles.css"?&gt;<BR>&lt;!DOCTYPE
    images =
    [<BR> &lt;!ELEMENT images=20
    (#PCDATA)*&gt;<BR>  
    &lt;!ELEMENT pic (image, thumbnails, =
    caption,=20
    desc)&gt;<BR>   &lt;!ELEMENT
    image =
    (#PCDATA)*&gt;<BR>  =20
    &lt;!ELEMENT thumbnails
    (#PCDATA)*&gt;<BR>   &lt;!ELEMENT =
    caption=20
    (#PCDATA)*&gt;<BR>  
    &lt;!ELEMENT desc=20
    (#PCDATA)*&gt;<BR> ]&gt;<BR>&lt;images&gt;<BR>   =20
    &lt;pic&gt;<BR>       =20
    &lt;image&gt;images/0.jpg&lt;/image&gt;<BR>  &lt;thumbnails&gt;=
    images/thumbs/wickham.swf&lt;/thumbnails&gt;<BR>    &=
    nbsp;  =20
    &lt;caption&gt;An Inspired=20
    Beginning&lt;/caption&gt;<BR>  &lt;desc&gt;Edward
    Virginius =
    Valentine=20
    was born in Richmond in 1838. A visit to the 1853 New York
    World's Fair =
    with his=20
    father inspired him to become an artist. Valentine studied in
    Paris and =
    Italy=20
    from 1859 to 1861. He was granted permission to study under
    Berlin =
    sculptor=20
    August Kiss, &lt;em&gt;who had created the piece that
    first ignited =
    Valentine=92s=20
    artistic inspiration, Amazon Attacked by a
    Tiger.&lt;/em&gt; In the =
    spring of=20
    1865, the deaths of both Kiss and his father, Mann Valentine,
    led him to =
    return=20
    to his home in Richmond,=20
    Virginia.<BR>  &lt;/desc&gt;<BR>   =20
    &lt;/pic&gt;</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>etc., etc.,
    ...</FONT></DIV>
    <DIV><FONT face=3DArial
    size=3D2></FONT> </DIV>
    <DIV><FONT face=3DArial
    size=3D2><STRONG>CSS doc:=20
    (xmlstyles.css)</STRONG></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>em
    {<BR> font-style: =
    italic;<BR>}<BR>para {=20
    <BR> font-size: 12px;<BR>}<BR>desc
    {<BR> font-size:=20
    12px;<BR> color:
    #0000CC;<BR>}</FONT></DIV></BODY></HTML>
    ------=_NextPart_000_0008_01C6AB1B.755FB0F0--

    Thank you! I will check it out.
    Raymond Basque" <[email protected]> wrote
    in message
    news:[email protected]...
    >
    >
    > You need to load the stylesheet using a
    TextField.StyleSheet object and
    > then
    > assign it to the TextField. There are examples in the
    Help documents.
    >
    >
    >
    >
    > "Dirk" <[email protected]> wrote in
    message
    > news:[email protected]...
    > Yes I want to use css for this.
    > I have an xml doc being pulled into my flash. Text is
    fine except wherever
    > I
    > try to assign a style. It's also defaulting to the black
    color in flash (I
    > couldn't find a way not to select a color or style in
    flash for the font)
    > instead of the blue specified in the css doc. In that
    first
    > image/description, it cuts off at the <em> tag.
    > Please help me understand what I'm doing wrong.
    >
    >
    > XML doc:
    > <?xml version="1.0" encoding="utf-8"
    standalone="yes"?>
    > <?xml-stylesheet type="text/css"
    href="xmlstyles.css"?>
    > <!DOCTYPE images [
    > <!ELEMENT images (#PCDATA)*>
    > <!ELEMENT pic (image, thumbnails, caption, desc)>
    > <!ELEMENT image (#PCDATA)*>
    > <!ELEMENT thumbnails (#PCDATA)*>
    > <!ELEMENT caption (#PCDATA)*>
    > <!ELEMENT desc (#PCDATA)*>
    > ]>
    > <images>
    > <pic>
    > <image>images/0.jpg</image>
    >
    <thumbnails>images/thumbs/wickham.swf</thumbnails>
    > <caption>An Inspired Beginning</caption>
    > <desc>Edward Virginius Valentine was born in
    Richmond in 1838. A visit to
    > the 1853 New York World's Fair with his father inspired
    him to become an
    > artist. Valentine studied in Paris and Italy from 1859
    to 1861. He was
    > granted permission to study under Berlin sculptor August
    Kiss, <em>who had
    > created the piece that first ignited Valentine's
    artistic inspiration,
    > Amazon Attacked by a Tiger.</em> In the spring of
    1865, the deaths of both
    > Kiss and his father, Mann Valentine, led him to return
    to his home in
    > Richmond, Virginia.
    > </desc>
    > </pic>
    > etc., etc., ...
    >
    > CSS doc: (xmlstyles.css)
    > em {
    > font-style: italic;
    > }
    > para {
    > font-size: 12px;
    > }
    > desc {
    > font-size: 12px;
    > color: #0000CC;
    > }
    >
    >

  • XML Shredding help.

    declare @x xml = '
    <obj xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:vim25"
    versionId="5.5" xsi:type="ArrayOfGuestStackInfo">
    <GuestStackInfo xsi:type="GuestStackInfo">
      <dnsConfig>
         <dhcp>false</dhcp>
      <hostName>YODA</hostName>
      <domainName>yoda.starwars.com</domainName>
      <ipAddress>127.0.0.1</ipAddress>
      <ipAddress>8.8.8.8</ipAddress>
      <ipAddress>9.9.9.9</ipAddress>
      <searchDomain>laya.starwars.com</searchDomain>
      </dnsConfig></GuestStackInfo>
    </obj>'
    ;WITH XMLNAMESPACES ('http://www.w3.org/2001/XMLSchema' AS xsd,'http://www.w3.org/2001/XMLSchema-instance' AS xsi,'ArrayOfKeyAnyValue' as type,'urn:vim25' as [default])
    SELECT t.u.value('(./default:dnsConfig)[1]','varchar(500)') as [Key]
    FROM @x.nodes('/default:obj/default:GuestStackInfo')t(u)
    undesirable output:
    falseYODAyoda.starwars.com127.0.0.18.8.8.89.9.9.9laya.starwars.com
    I want this output:
    dhcp Hostname domainname          ipaddress searchDomain
    false YODA       yoda.starwars.com 127.0.0.1 laya.starwars.com
    false YODA       yoda.starwars.com 8.8.8.8     laya.starwars.com
    false YODA       yoda.starwars.com 9.9.9.9     laya.starwars.com
    XML name spaces confuses me.  Please help. Thanks in advance.
    -scott
    scott

    ;WITH XMLNAMESPACES ('http://www.w3.org/2001/XMLSchema' AS xsd,'http://www.w3.org/2001/XMLSchema-instance'
    AS xsi,'ArrayOfKeyAnyValue' as type,'urn:vim25' as [default])
    SELECT t.u.value('(./default:dhcp/text())[1]','varchar(5)') as DHCP,
           t.u.value('(./default:hostName/text())[1]','varchar(50)') as hostName,
           t.u.value('(./default:domainName/text())[1]','varchar(500)') as domainName,
           t.u.value('(./default:searchDomain/text())[1]','varchar(500)') as searchDomain,
           IP.c.value('(./text())[1]', 'varchar(15)') AS IPaddress
    FROM @x.nodes('/default:obj/default:GuestStackInfo/default:dnsConfig')t(u)
    OUTER APPLY t.u.nodes('default:ipAddress') IP(c)
    Erland Sommarskog, SQL Server MVP, [email protected]

  • Need with xml manipulation(help!!!)

    am trying to use jdom to manipulate an xml file...can anybody help on how to achieve this structure below.
    I have an xml file in this form
    <test name ="x " value="y">
    <id name="d" value="1"/>
    <id name="d" value="1"/>
    <id name="d" value="1"/> </test>
    <test name ="x " value="b">
    <id name="d" value="2"/>
    <id name="c" value="2"/>
    <id name="c" value="2"/>
    </test>
    I want to attain this below:
    <test name ="x " value="y">
    <id name="d" value="1"/>
    <id name="d" value="1"/>
    <id name="d" value="1"/>
    <test name ="x " value="b">
    <id name="d" value="2"/>
    <id name="c" value="2"/>
    <id name="c" value="2"/>
    </test>
    </test>
    The second element "test" is a child of the first element...is there a way to manipulate this to get that nesting right?

    I should think your problem is that the first of these isn't actually a valid XML document (should be a single, top level tag. Consequently a DOM approach probably won't parse it.
    I'd be inclined to turn it into a valid document first (by putting the whole thing in some new tag. Then you can turn it into a DOM, move the extra test nodes and dump it out again using the transform stuff.

  • XML function help needed

    I am inserting an xml doc into a table with a CLOB column and have a Query such as this inside a dbms_xmlgen function :-
    SELECT XMLELEMENT("provider", XMLForest(DECODE(a1.CORP_ID,''D'',13478,''RR'',14450) as"provider-id"),
    xmlagg(XMLELEMENT( "Employee", XMLForest ( a18.EMP_FIRST_NM "first-name", a18.EMP_LAST_NM "last-name" ),XMLELEMENT("enc", XMLATTRIBUTES ( 'PWE-IL' AS "measure-set"),XMLForest ( a110.PP_DESC as "enc-flag",a18.EMP_ID as "emp-id",a12.EMP_AUX_RECORD_NBR as "Employee-group-number") )))) as "provider" .
    I want to supress the duplicated PROVIDER nodes in the resulting doc. If I remove the 'AS PROVIDER' tag, it takes the xml function XMLELEMENT on the first line as the NODE.
    I am at my wits end trying to get the duplicate tag out of the way. Please help...
    VR

    I want to supress the duplicated PROVIDER nodes in the resulting docWhat duplicate nodes are you talking about?:
    SQL> select xmlelement("provider", deptno, xmlagg(xmlelement(ename, ename))) as "provider" from emp
    group by deptno
    provider                                                                              
    <provider>10<ENAME>CLARK</ENAME><ENAME>KING</ENAME><ENAME>MILLER</ENAME></provider>   
    <provider>20<ENAME>SMITH</ENAME><ENAME>FORD</ENAME><ENAME>ADAMS</ENAME><ENAME>SCOTT</EN
    AME><ENAME>JONES</ENAME></provider>                                                   
    <provider>30<ENAME>ALLEN</ENAME><ENAME>BLAKE</ENAME><ENAME>MARTIN</ENAME><ENAME>TURNER<
    /ENAME><ENAME>JAMES</ENAME><ENAME>WARD</ENAME></provider>  

Maybe you are looking for

  • How do I get a Stable pdf to Google Documents?

    i am posting a pdf created in Mac Pages to Google Documents and the font is getting changed. Is there a way to open this document in my new version of Acrobat Pro and save it out so that the font won't change? TIA!

  • Generic Object Service (GOS)

    Can anyone tell me for what documents that the GOS is available. Generally I need to know whether it is available for all logistics documents and whether other types if so what are the types. Thanks

  • Message security while using JMS

    Hello, In PI7.0 we are using JMS adapter to pull data from another MQ system. How can we make this call secure? I mean, during data transfer using FTP or HTTP, we can use FTPS or HTTPS. In case of JMS, is there any way in which message security can b

  • Question of CONF?

    Hi Friends Please let me know: 1. How to do return delivery of goods receipt & service entry sheet between EBP to SUS in ECS,SRM5.0 2. How to cancel confirmation of goods receipt and service entry sheet between EBP to SUS Regards Renuka

  • Can't send email after updating to snow leopard with Mail

    I can still receive emails. SMTP settings were not changed. I can send with Entourage using the same settings. any help ? thanx in advance