How to bind XML to Datagrid?

My xml is here:
<?xml version="1.0"?><ITRequests><CallInfo><id type="INT UNSIGNED">42</id><request_no type="VARCHAR">1313_IT_220520100709</request_no><requester_uid type="VARCHAR">administrator</requester_uid><request_date type="VARCHAR">22-May-2010 07:09:34 PM</request_date><title type="VARCHAR">Printer Installation</title><status type="VARCHAR">Closed</status></CallInfo><CallInfo><id type="INT UNSIGNED">43</id><request_no type="VARCHAR">1314_IT_220520100718</request_no><requester_uid type="VARCHAR">administrator</requester_uid><request_date type="VARCHAR">22-May-2010 07:17:49 PM</request_date><title type="VARCHAR">Software Installation</title><status type="VARCHAR">In Progress</status></CallInfo><CallInfo></ITRequests>
I don't know how to bind this to a simple datagrid.
Can someone help me please?
PS: The data is in a String variable.
Thanks,
Nith

Getting your data in the form a string is a PITA. Can you just use the XML itself, and convert it to an ArrayCollection? Then you could just use an HTTP request, for instance, to retrieve it.
Anyway, here is the code you need. It also demonstrates using E4X syntax to filter out the root node.
<?xml version="1.0" encoding="utf-8"?>
<mx:Application 
xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"creationComplete="initApp()"
>
<mx:Script>
<![CDATA[
import mx.collections.XMLListCollection; 
import mx.collections.ArrayCollection; 
private var strData:String = "<?xml version='1.0'?><ITRequests><CallInfo><id type='INT UNSIGNED'>42</id><request_no type='VARCHAR'>1313_IT_220520100709</request_no><requester_uid type='VARCHAR'>administrator</requester_uid><request_date type='VARCHAR'>22-May-2010 07:09:34 PM</request_date><title type='VARCHAR'>Printer Installation</title><status type='VARCHAR'>Closed</status></CallInfo><CallInfo><id type='INT UNSIGNED'>43</id><request_no type='VARCHAR'>1314_IT_220520100718</request_no><requester_uid type='VARCHAR'>administrator</requester_uid><request_date type='VARCHAR'>22-May-2010 07:17:49 PM</request_date><title type='VARCHAR'>Software Installation</title><status type='VARCHAR'>In Progress</status></CallInfo></ITRequests>";[
Bindable] 
private var acData:ArrayCollection; 
private function initApp():void{     getCallInfo();
private function getCallInfo():void{ 
//Convert string to XML:
var sxml:XML = new XML(strData); 
//Create an ArrayCollection.
//Just get the 'CallInfo' nodes (ignoring the root node, 'ITRequests'):
acData =
new ArrayCollection(new XMLListCollection(new XMLList(sxml..CallInfo)).toArray()); 
trace(acData);}
]]>
</mx:Script>
<mx:DataGrid 
dataProvider="{acData}">
     <mx:columns>
          <mx:DataGridColumn dataField="id" width="50"/>
          <mx:DataGridColumn dataField="request_no" width="180"/>
     </mx:columns></mx:DataGrid>
</mx:Application>

Similar Messages

  • How to bind xml generated by guide in Soap request message and then unbind it?

    Hi
    I have issue in "invoke web service" in adobe LC process ?
    Actually , i have process, a long lived, which take input as xml . this xml(data) it get from guide data submission in browser by user?
    Now , what i need to achieve here is that i have to invoke this long lived process in one of my other process via "invoke web service" option.And to do that, i need to bind the xml into Soap message and then it unbind to back same xml in the other process to use it?
    so, my question here is how can i achieve that?

    Hello Iñaki
    Thanks for your reply.
    I had read the blog about the XMLAnonymizerBean. It looks very straightforward, and in theory should do just what I need.
    I've added the anonymizer bean as the first module as the SOAP message is asynchronous, and I want to remove the namespaces from the request.
    I want to exclude all namespaces so I haven't set any parameters.
    The SOAP channel in Communication Channel monitor has a status of 'Channel Started but inactive'. I cannot see any messages in the Processing Details for this channel, even though I have sent test messages from Java code and from RWB (the message from RWB without the namespace does reach the receiver). This makes me wonder if I have not configured the interface to use the new SOAP channel correctly, although I can see it in the Receiver Determination configuration overview.
    I can see the messages in SXMB_MONI but can't find which communication channel is being used by the sender.
    I'm using PI 7.1.
    regards
    Steve

  • How to bind xml or any data to a mobile list in Dreamweaver?

    I am trying to figure out what should be a simple thing in Dreamweaver.
    That is while using jquery mobile, how do I attach an xml file to the attribute list elements?
    If that isn't possible, would someone be able to tell me or direct me to a way to handle data within Dreamweaver for mobile apps. I'm over the top trying to figure out all of the technologies. It appears that HTML5, xml, sqlite, and json all have possibilities. I have a simple database of maybe 300 items: an image and a description. The data will reside and be read client side on the mobile app.
    I want to read the items into a list. Then call up individual items on a new "page" based on the user's list item selection. This is so easy in Dashcode under Mac. Surely, I must be missing something in Dreamweaver 5.5.
    TIA to anyone who tries to point me in the right direction.

    Have a look here http://books.google.com.au/books?id=kJ5ZWFZtWFgC&pg=PA113&lpg=PA113&dq=spry+datasets+and+j query+mobile&source=bl&ots=l8vMEvoRZn&sig=rZYgQGSdsxX64jCQPnFFqJdMwFg&hl=en&sa=X&ei=xpwPT8 GRIumiiAeztrQK&sqi=2&ved=0CF4Q6AEwBw#v=onepage&q=spry%20datasets%20and%20jquery%20mobile&f =false (apologies for the lenth of the URL) and here http://foundationphp.com/dwmobile/
    Gramps

  • How to bind XML in Actionscript?

    I'm having difficulty working with binding in actionscript.  In MXML I can use the following line:
    <mx:Label x="117" y="40" text=" {stationXML.getItemAt(Station-1).CDL0.@value}" id="lblTest"/>
    However, in actionscript, I cannot seem to get the binding to work! I tried the following:
    BindingUtils.bindProperty(lblTest,"text",stationXML.getItemAt(Station-1).CDL0,"value");
    Any ideas how I can do this in Actionscript?  I need to do it in ActionScript becuase the "CDL0" value will need to be replaced at times with "CDL1", "CDL2", etc...

    I solved the issue, so if anyone else has the same problem, here's what I did (after much aggravation):
    The reason I didnt use MXML binding was because I wanted to be able to change it from "CDL0" to "CDL1" to "CDL3" without manually changing bindings.
    What I set in MXML for the text was:
    {stationXML.getItemAt(Station-1).child(cdlstr).@value}
    where 'cdlstr' was a public string declared (and set) elsewhere in the program.
    So I could make 'cdlstr' = "CDL0" or "CDL1" or even "CDL" + i (if I wanted to make life easy).  Just needed to remember to make 'cdlstr' a bindable variable or else it all falls apart.
    Hope it helps someone else.

  • How to bind list data to XML Web service request

    How do I bind specific columns in a DataGrid to the Web
    service request? I'm having trouble finding any documentation that
    addresses that specific pattern, i.e. sending a complex list to the
    server via a Flex Web service send() command. I'm fairly new to
    Flex programming and don't know if what I want to do is possible.
    Here what I've been able to do so far.
    1. Using a Web service called a service on the server and
    retrieved a complex list.
    2. Poplulated a DataGrid with the result
    3. The user has selected multiple rows from the DataGrid
    using a checkbox column
    4. The user pressed a button that calls a Web service send().
    This Web service should only send data from only two columns and
    only for those rows the user has checked.
    5. I can loop over the DataGrid and find the selected rows
    and put them in another ArrayCollection called 'selectedRows'.
    The issue is that I don't know how to bind 'selectedRows' to
    the Web service. Right now I'm reading up on "Working with XML" in
    the Programming with ActionScript 3.0 chapter. But I'm just fishing
    here. No bites yet.

    Don't bind. Build the request object programatically, as you
    are doing with your selectedRows AC, and send(myObject) that.
    Tracy

  • How to bind each DataGrid column separately?

    Good day fellow Flex developers!
    Could you please help me out. I am trying to figure out how to bind each DataGrid column separately. I need to bind each column to a separate bindable array variable. Is there a dataProvider property for each DataGridColumn???
    Thanks in advance,
    Eugene

    hopefully nope
    just imagine code complexity for that feature?
    how would you think should behave DataGrid when you'll populate your separate arrays with variable items number each?
    all you are able and should do is to build composite dataProvider source, join all your separate arrays into it, this is your responsibility.
    If you feel this message answers your question or helps, please mark it respectively

  • Binding XML

    Hi all,
    I'm working with XML but creating a binding between the
    xmlconnector, the dataset and the the datagrid with the usage of
    actionscript only (No dragging of components 2 the stage,
    components are in the libary, that's not the problem) isn't working
    at all. The results of the current code return nothing, however,
    binding the XMLconnector to a textarea works fine. The problem lies
    within the binding with dataset and datagrid! PLZ HELP ME Here is
    some code:

    I think something like:
    Name="Child" DataContext="{Binding ElementName=someotherelement, Path=SelectedItem}"
    And then use xpath on that again.
    xpath is very powerful.
    I can't say I use it so much since I do line of business apps and they're very database orientated.  Usually.
    Hope that helps.
    Technet articles: Uneventful MVVM;
    All my Technet Articles
    Excuse me, are not yet practical with XPATH.
    How come it takes me all the PARAM and not just those of the selected PAGE?
    Where am I wrong?
    <DataGrid Name="grid1" Grid.Row="0" DataContext="{StaticResource ConfigData}"
    ItemsSource="{Binding XPath=//Page}"
    AutoGenerateColumns="False">
    <DataGrid.Columns>
    <DataGridTextColumn
    Header="pageName"
    Binding="{Binding XPath=@pageName}"/>
    <DataGridTextColumn
    Header="description"
    Binding="{Binding XPath=description}"/>
    </DataGrid.Columns>
    </DataGrid >
    <DataGrid Grid.Row="1" DataContext="{Binding ElementName=grid1, Path=SelectedItem}"
    ItemsSource="{Binding XPath=//Param}"
    AutoGenerateColumns="False">
    <DataGrid.Columns>
    <DataGridTextColumn
    Header="name"
    Binding="{Binding XPath=name}"/>
    <DataGridTextColumn
    Header="address"
    Binding="{Binding XPath=address}"/>
    </DataGrid.Columns>
    </DataGrid>

  • How to bind korean parameters in XSQL????

    Hi,
    I am binding english parameters in XSQL very well.
    But when I am trying to bind japaneese or korean it is not displaying rows.
    I am giving the sample code.
    hello.xsql
    <?xml version="1.0" encoding="euc-kr"?>
    <xsql:query connection="scs" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:xsql="urn:oracle-xsql" row-element="ADDRESSES_ROW">
    select * from emp where name='{@name}'
    </xsql:query>
    Request: http://hello.xsql?name=JOHN ::: working fine
    Request: http://hello.xsql?name=koreanName :::Not working
    Please help me in this regard.
    How to bind name in korean in XSQL servlet..
    Regards,
    sudhi

    Do you have nlscharset_12.jar in your classpath?
    what web server are you using XSQL with?
    Have you tried using real bind variables like this:
    <xsql:query bind-params="name">
    select * from emp where ename = ?
    </xsql:query>
    Does a query like:
    <xsql:query bind-params="name">
    select * from emp
    </xsql:query>
    return the korean data to the browser correctly?

  • How to bind dynamic data to JNet

    Develop tools: NWDS 7.1
    Server: Windows2000
    Does anyone have experiences with using JNET within Webdynpro Project ?
    In our case, we use JNet to generate a hierachical network diagram in the Webdypro's GUI. The data source is from the tables in a DB. However, till now, we only know how to let JNet generate the network diagram from a static XML file.
    Since the data in the DB changes all the time, how to let the network diagram reflect the newest data status automatically? That is, how to bind JNet to a dynamic data source then?

    Hi,
    Network UI element is related with Jnet. What you need to start up working with this is you need to create a context structure mentioned below.
    Node:Source
    Element--- xml -> this should be of type binary.
    Place the following code in the init.
    ISimpleTypeModifiable mod = wdContext.nodeSource().getNodeInfo().getAttribute("xml").getModifiableSimpleType();
    IWDModifiableBinaryType bin = (IWDModifiableBinaryType)mod;
    bin.setMimeType(new WDWebResourceType("xml", "application/octet-stream", false));
    ISourceElement element =wdContext.nodeSource().createSourceElement();
    wdContext.nodeSource().addElement(element);
    try
    fileName = WDURLGenerator.getResourcePath(wdComponentAPI.getDeployableObjectPart(), "jnettest.xml");
    element.setXml(readFile(fileName));
    catch (WDAliasResolvingException e)
    You have to place the Jnet test.xml under the mimes folder of your application.
    Place the network element in the view and in the data source specify the context attribute source.xml
    if your xml file complies with the jnet schema your application will render it.
    Pl go through this
    Using the "Network" UI Element
    Regards
    Ayyapparaj

  • How to delete xml tags Urgent

    on release function i am inserting this value
    "(&-box*&", "&*box-&
    " in to my text box,
    in text box will display like this (squarebox), when i am
    trying to delete
    squarebox ,
    box deleting but
    (&-box*&", "&*box-&
    these xml elements are showing , what i have to
    do ? it has to delete,
    it amy have multipule box in my equation. how do delete xml
    elements in this case, this is my xml code. how to delete? any one
    can help me?

    Then you should provide more details on what you want this new script should do.
    To "delete XML tags in already tagged text", all you need is use the "untag" command on an XML Element. But how would the script "know" what XML Element should be untagged?
    Disclaimer: This reply is in no way enforceable, legally binding, a promise or contract, an agreement (written, verbal, or otherwise), a commitment, obligation, or free or paid-for offer of any kind to further help, guide, aid, tip, or not hinder you, or contribute to, correct, investigate, comment on or assist with any existing, forthcoming, or planned project.

  • ActionScript to bind XML data to components

    How can I use ActionScript to bind XML data to a comboBox
    component instead of using the component inspector? (I have done
    the latter, successfully, but that doesn’t allow access to
    the code - .)
    My ActionScript so far imports the data (the trace picks it
    up) – but the ‘cbType.dataProvider line’
    doesn’t work. It works when I change the data provider to an
    array – so what am I doing wrong?
    MY CODE:
    import mx.data.components.XMLConnector;
    var xcFestival:XMLConnector = new XMLConnector();
    xcFestival.ignoreWhite = true;
    xcFestival.direction = "receive";
    xcFestival.URL = "festivalItems.xml";
    xcFestival.trigger();
    //POPULATE THE COMPONENTS WITH THE DATA
    var festXMLlistener:Object = new Object();
    festXMLlistener.result = function(evt:Object) {
    trace(xcFestival.results);
    cbType.dataProvider = xcFestival.results;
    xcFestival.addEventListener("result",festXMLlistener);

    This is on a stand - alone system
    Using Designer ES ......
    I saved the Form as an xdp form
    and it seems as if all goes well until
    View the data and nothing appears - or
    just the names of the fields appear

  • Clientgen with JAXWS -- how to bind with JAXB?

    I'm using WLS 10.0 "clientgen" to generate Java classes from my WSDL files. All goes well for the simpler WSDL files. Since I'm new to JAXB, I don't quite understand now how to bind the output files using JAXB. It seems this would have been done in the 'clientgen' process, but I don't see any parameters for this in the documentation/help output.
    Here's the ant snippet:
    <target name="wsdl2java" depends="init" >
    <clientgen
    type="JAXWS"
    wsdl="${sitedata.wsdl.file}"
    destDir="${generated.class}"
    serviceName="SiteData"
    packageName="${output.package}.sitedata"/>
    </target>
    How can this be done?

    The <binding> child element of the WLS 10.0 wsdlc Ant task, does in fact allow you to pass a .xjb file to the wsimport Ant task. wsdlc calls wsimport internally.
    When you do this, you want to do all of your namespace-to-Java-package mapping in the .xjb file, and not specify the packageName attribute on the wsdlc Ant task. In fact, doing the latter will override the mapping specified in the .xjb file.
    Here's a sample Ant target that shows what this looks like:
    <target name="run-wsdlc" depends="clean">
    <taskdef name="wsdlc" classname="weblogic.wsee.tools.anttasks.WsdlcTask" classpathref="compile.classpath" />
    <mkdir dir="${src.dir}"/>
    <property name="client.binding" value="custom-client.xjb"/>
    <wsdlc
    type="JAXWS"
    srcWsdl="etc/${wsdl.file.name}.wsdl"
    destJwsDir="WebContent/WEB-INF/lib"
    destImplDir="${src.dir}"
    explode="false"
    verbose="${verbose}"
    debug="${debug}"
    failonerror="true"
    >
    <binding dir="etc" includes="${client.binding}"/>
    <classpath>
    <path refid="compile.classpath"/>
    </classpath>
    </wsdlc>
    </target>
    And here's the contents of the custom-client.xjb file:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <bindings
    xmlns:jxb="http://java.sun.com/xml/ns/jaxb"
    xmlns="http://java.sun.com/xml/ns/jaxws"
    wsdlLocation="DataStagingService2.wsdl"
    >
    <bindings
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xs="http://www.w3.org/2001/XMLSchema"
    node="wsdl:definitions"
    >
    <package name="services.datastaging">
    <jxb:javadoc>
    <![CDATA[<body>Package level documentation for generated package services.datastaging.</body>]]>
    </jxb:javadoc>
    </package>
    <jxb:schemaBindings>
    <jxb:package name="com.acmeworld.irad.services.datastaging"/>
    </jxb:schemaBindings>
    </bindings>
    </bindings>
    The targetNamespace attribute for the DataStagingService is http://www.acmeworld.com/irad/services/datastaging. The above .xjb file says to map this to the services.datastaging Java package, but the skeleton JAX-WS service endpoint implementation class that wsdlc generates, doesn't currently honor this. The JAXB generated classes will be as specified in the .xjb file, but you'll need to manually refactor the Java package name of the wsdlc generated JAX-WS skeleton class, to be services.datastaging.
    I'll be publishing a series of articles on using JAXB and JAX-WS with WebLogic 10.0, so look out for them in the coming months :-)
    HTH,
    Mike Wooten

  • How to bind soap header using jax-rpc

    To Whom It May Concern:
    I am using Rad7, Ibm Websphere 6.1, on Windows XP.
    I created an SoapHeader first using a string and bind it using jax-ws.
    It works for jax-ws but unfortunately, my work services uses jax-rpc.
    Does anybody know how to bind the soap header using jax-rpc.
    Any help or hint would be greatly appreciated it.
    Here is my code:
    import org.apache.cxf.headers.Header;
    import org.apache.cxf.headers.Header.Direction;
    import org.apache.cxf.helpers.DOMUtils;
    import org.apache.cxf.binding.soap.SoapHeader;
    import javax.xml.namespace.QName;
    import java.io.StringReader;
    import java.util.List;
    import java.util.ArrayList;
    import javax.xml.ws.BindingProvider;
                   @Test
         public void testService() throws Exception {     
                   try
                        URL wsdlURL = new URL("http://localhost:9087/abc/services/ServiceABCService");
                        ServiceRequestServiceService service = new ServiceRequestServiceServiceLocator();
                        ServiceRequestService port = service.getServiceRequestService(wsdlURL);
                   //How to Add Soap Header using jax-ws
              String xml = "<?xml version=\"1.0\" encoding=\"utf-8\"?><ABCHdrRq "
              + "xmlns=\"http://xmlns.ABCgc.net/ABC/2002/header/\" "
              + ">"
              + "<version>1.0</version><srcInfo><chType>abc</chType><chInst>0124</chInst>" +
                        "<appName>sSAR</appName><hostName>DW70210521</hostName><userId>fxue</userId>" +
                        "</srcInfo><startTimeStamp>2010-06-04T13:44:45.132</startTimeStamp><clientDt>2010-06-04T13:44:53.242</clientDt><serviceInfo><serviceName>ServiceRequestService</serviceName>" +
                        "<serviceFunc>addServiceRequest</serviceFunc></serviceInfo>" +
                   "<prevTransInfo><prevRqUID>BORS2010-06-04T13:41:10.2067f9368d1-8c5c</prevRqUID>" +     
                   "<prevRespTimestamp>2010-06-04T13:41:10.871</prevRespTimestamp>"+
                   "<prevRespEndTimestamp>2010-06-04T13:41:10.902</prevRespEndTimestamp>+</prevTransInfo>"+
                   "</ABCHdrRq>";
              SoapHeader dummyHeader1 = new SoapHeader(new QName("uri:http://xmlns.ABCgc.net/ABC/2002/header/", "ABCHdrRq"),
              DOMUtils.readXml(new StringReader(xml)).getDocumentElement());
              dummyHeader1.setDirection(Direction.DIRECTION_OUT);
              List<Header> headers = new ArrayList<Header>();
                   headers.add(dummyHeader1);
                   ((BindingProvider)port).getRequestContext().put(Header.HEADER_LIST, headers);
                   //How to Add Soap Header to the request using jax-ws
                   catch(Exception e)
                        System.out.println("Exception message:"+e.getMessage());
    Yours,
    Frustrated

    Well, how an attachment is processed depends on your application logic...if your application logic requires to processing attachments and verify it before processing the SOAP message, handlers could be better option.
    If you need to process the attachment while processing the SOAP message, you can do it in the service implementation class.
    In both the cases you need to get access to SOAPMessage object and from there get the attachments with getAttachments method.

  • How to access XML elements by name in Extendscript??

    I'm almost done the script that I've been working on, but something has been nagging me since I started. When I did start, I looked at the JS Tools Guide CS5 that comes with the extendscript ide to check how to access XML elements, children, attributes etc. It says this:
    The XML object represents an XML element node in an XML tree. The topmost XML object for an XML file
    represents the root node. It acts as a list, which contains additional XML objects for each element. These in
    turn contain XML objects for their own member elements, and so on.
    The child elements of an element tree are available as properties of the XML object for the parent. The
    name of the property corresponds to the name of the element. Each property contains an array of XML
    objects, each of which represents one element of the named type.
    So basically it converts the XML into JSON. And you can access the properties like so:
    <book category="COOKING">
         <title lang="en">The Boston Cooking-School Cookbook</title>
         <author>Fannie Merrit Farmer</author>
         <year>1896</year>
         <price>49.99</price>
    </book>
    The Javascript statement bookstoreXML.book; returns the entire list of books.
    The statement bookstoreXML.book[0]; returns the XML object for the first book.
    The statement bookstoreXML.book[0].author; returns all authors of the first book.
    A couple pages down it talks about Retrieving contained elements using children(), elements(), descendants().
    So now I look through the XML Object properties and I see that I can use:
    xmlObj.child (which) which A String, the element name, or a Number, a 0-based index into this node’s child array.
    or
    xmlObj.descendants ([name])
    name Optional. A String, the element name to match. If not provided, matches all
    elements.
    or
    xmlObj.elements (name);
    name Optional. A String, the element name to match. If not provided, matches all
    elements.
    This is an excerpt of an XML I was working with:
    <ROW xmlns="http://www.filemaker.com/fmpdsoresult"
         MODID="16"
         RECORDID="11128">
       <Sign_Type>251.dr</Sign_Type>
       <fm:Location xmlns:fm="http://www.filemaker.com/fmpdsoresult" xmlns="">5-5024</fm:Location>
       <Line1>Zone
    Floor
    3
    Patient Rooms
    R532 - R436 even
    Patient Rooms
    R522 - R446 even
    Xavier Elevators
    Zone
    Patient Rooms
    R537 - 5757 odd
    Main Elevators
    Zone</Line1>
    </ROW>
    Extendscript will not give me an anything when I try to access elements by name. Instead I have to access by index, which works, but I'd rather search for names!
    Actually the console log returns: <![CDATA[]]>
    What am I doing wrong!?

    First, those E4X XML objects are definitely no JSON (plain data) - they have a multitude of methods, even for tasks that would easily be implemented as property (e.g. the length() function), and they also bind xml element and attribute names onto the objects, allowing to target a multitude of XML nodes with a single statement. Or did you mean your script with that "it"?
    Anyway, as you found out the ExtendScript XML object handles namespaces mostly by hiding them from you.
    You could play around with global namespace settings, see the JavaScript tools guide.
    You could also explicitly specify a namespace. This works for me:
    $.writeln(myXML["fm:Location"]);
    For simple use I had most success with a brute force approach that just strips the namespaces.
    function removeAllNamespace(xml)
              var ns =new Namespace();
              var d=xml.descendants();
              for (var i=0;i<d.length();i++)
        d[i].setNamespace(ns);

  • Binding XML to java types generated using Oracle Class Gen

    Hi,
    how can you bind an XML to the java types generated using the class gen provided byOracle.
    I am using oracle 9i production. as part of my design, i have to read an xml input in my java class and use the contents to create some records and send a response xml back.
    The latter part of i can do as the java types provide setter methods to set the data and conversion to xml.
    Jaxb can be using to bind xml to java datatypes but its not supported in Oracle9i.
    What are the alternatives for achieving the same?
    Thanks
    Ashwin

    Hi Ashwin,
    This is a bit outside my area of expertise, but I did run an older version of TopLink in the Oracle database java VM a few years back so I'll base my advice on that. Hopefully other forum members can correct me if I steer you wrong.
    First you will need to set up your XML environment:
    I believe the Oracle 9i database includes a JDK 1.3 VM. You will first need to determine if the VM includes any JAXP APIs. I believe there is an SQL query that allows you to query the classes available in the VM. First check if javax.xml.parsers.DocumentBuilderFactory is present.
    If the JAXP APIs are already present in the database you will need to do the following. First load the class javax.xml.namespace.QName into the database. You can extract this from xmlparserv2.jar or from Suns Java Web Service Developer Pack jax-qname.jar. Then you will need to load the JAXB APIs. You can load xml.jar or jaxb-api.jar from Sun's JWSDP.
    If the JAXP APIs are not present you will need to load the 10.1.3 version of the XDK jars (these are shipped with the 10.1.3 TopLink install). Load xmlparserv2.jar and xml.jar into the database.
    Second you will need to setup your TopLink environment:
    Load toplink.jar into the database. If the JAXP APIs were already present and you didn't load the 10.1.3 XDK jars into the database you will need to set the following System property.
    toplink.xml.platform=oracle.toplink.platform.xml.jaxp.JAXPPlatform-Blaise

Maybe you are looking for

  • How do I get a webpage to print in a larger font?

    When I increase the size of the font in internet options, it helps the printed page, but increases the size of the webpage so much it is way too large. How can I increase just the size of my printed page?

  • Pictures are not showing up in iphoto

    I am running iphoto 9.4.2.   I recently noticed a picture I knew that should be in my iphoto library was not showing up.  I opened finder and found the iphoto library to show the contents I right clicked and found the photo in the masters/originals a

  • I need to create a .pdf of a CAD (Microstation) file with a bitmap embedded

    every plot driver I have tried will not include the bitmaps (3 of them in the title block of the drawing) in the .pdf. All of the other elements are created but not the bitmaps. I am using MicroStation V8 XM edition. Thank you, John

  • Create an XI webservice and import it to the NWDS

    Hi all, i created a webservice via the "define webservice" option in XI/PI. But when i try to use it in my NWDS the following error occurs: Exception on creation of service metadata for WSDL URL ...... I read multiple threads and blogs about defining

  • My photo booth won't close down -

    i am trying to close down programs but the photo booth won't close i've tried apple Q but the little rainbow circle keeps spinning.. help!