Modification of xml

Hi All,
When i use code as
Element rootEle = dom.createElement("packageBody");
rootEle.setAttributeNS("http://www.w3.org/2001/xmlns/",
"xmlns:xsi",
"http://www.w3.org/2001/XMLSchema-instance");
I get o/p as
<packageBody xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance">
How shd i modify my code to get o/p as
<packageBody xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.vignette.com/xmlschemas/importexport"
xsi:schemaLocation="http://www.vignette.com/xmlschemas/importexport 7201/packageBody.xsd">
Thanks in advance

You are saying that you want that packageBody element to be in the default namespace, whose namespace URI is "http://www.vignette.com/xmlschemas/importexport". But you are creating it using the createElement method, which creates elements that are not in a namespace. Use the createElementNS method to create elements that are in a namespace. In your example:
Element rootEle = dom.createElementNS("http://www.vignette.com/xmlschemas/importexport", "packageBody");

Similar Messages

  • Country ,state and city checklist XML by JAVA

    Hi friends,
    I have textboxes for entering the country ,state and city values and all these 3 fields are related by primary/foreign keys.
    I wan now store and retrieve values entered by users for country state and city by xml files .I also wan all these 3 field to be interrelated so that based on value of country I can populate the related states dropdownlist and based on value of state I can populate the related cities dropdownlist.Can some one pls answer my question about STORING AND RETRIEVING COUNTRY STATE AND CITY FIELDS USING XML FILES?
    I also did this application using string(short cut) way but is not efficient and all I want is direct modification in XML file by java?
    I didnt put my codes here bcos it so long and still if any one want my codes i wll email u sperately.
    All I need is any example approach for this kind?
    Any one help will be appreciated...

    Using XMLEncoder
    by Philip Milne
    This article covers advanced use of XMLEncoder, showing how it can be configured to create archives of any Java objects -- even when they don't follow the JavaBeans conventions. We include examples of how to make properties 'transient' and how to create archives that call constructors with arguments, use static factory methods, and perform non-standard initialization steps. We also cover exception notification, the 'owner' property (which can be used to a link an archive to the outside world), and methods for creating internationalized archives.
    http://java.sun.com/products/jfc/tsc/articles/persistence4/index.html

  • Error when deploying JDeveloper 11 to standalone WebLogic 10.3

    I followed the instructions at:
    http://groundside.com/blog/DuncanMills.php?title=a_rough_guide_to&more=1&c=1&tb=1&pb=1
    and
    http://one-size-doesnt-fit-all.blogspot.com/2009/01/configuring-weblogic-server.html
    to setup a standalone WebLogic 10.3 server with ADF libraries.
    When attempting to deploy an application to a standalone WebLogic 10.3 server on another machine, I get the following error:
    ----  Deployment started.  ----    Apr 3, 2009 1:10:42 PM
    Target platform is  (Weblogic 10.3).
    Running dependency analysis...
    Building...
    2009-04-03 13:10:47.798: Writing WAR file to /home/klee/jdevhome11/mywork/HDR/ViewController/deploy/hdr.war
    2009-04-03 13:10:48.27: Wrote WAR file to /home/klee/jdevhome11/mywork/HDR/ViewController/deploy/hdr.war
    Deploying Application...
    [Deployer:149034]An exception occurred for task [Deployer:149026]deploy application hdr on ManagedServer.: Failed to load webapp: 'hdr.war'.
    weblogic.application.ModuleException: Failed to load webapp: 'hdr.war'
    ####  Deployment incomplete.  ####    Apr 3, 2009 1:11:33 PM
    Deployment FailedFrom the ManagedServer.log file, I have the following:
    ####<Apr 3, 2009 1:11:32 PM MDT> <Error> <HTTP> <its-ucm01.dcsdk12.org> <ManagedServer> <[STANDBY] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1238785892160> <BEA-101371> <There was a failure when processing annotations for application /u01/app/bea/user_projects/domains/dcsd_domain/servers/ManagedServer/stage/hdr/hdr.war. Please make sure that the annotations are valid. The error is oracle.adf.model.servlet.ADFBindingFilter>
    ####<Apr 3, 2009 1:11:32 PM MDT> <Info> <Deployer> <its-ucm01.dcsdk12.org> <ManagedServer> <[STANDBY] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1238785892181> <BEA-149061> <Module hdr.war of application hdr failed to transition from STATE_NEW to STATE_PREPARED on server ManagedServer.>
    ####<Apr 3, 2009 1:11:32 PM MDT> <Error> <Deployer> <its-ucm01.dcsdk12.org> <ManagedServer> <[STANDBY] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1238785892194> <BEA-149265> <Failure occurred in the execution of deployment request with ID '1238785885980' for task '1'. Error is: 'weblogic.application.ModuleException: Failed to load webapp: 'hdr.war''
    weblogic.application.ModuleException: Failed to load webapp: 'hdr.war'
         at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:387)
         at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:42)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191)
         at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:16)
         at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:155)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:197)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:89)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:723)
         at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1190)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:248)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:157)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:12)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:45)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    java.lang.ClassNotFoundException: oracle.adf.model.servlet.ADFBindingFilter
         at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:283)
         at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:256)
         at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:54)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
         at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:176)
         at weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:35)
         at weblogic.servlet.internal.WebAnnotationProcessorImpl.processFilters(WebAnnotationProcessorImpl.java:240)
         at weblogic.servlet.internal.WebAnnotationProcessorImpl.processJ2eeAnnotations(WebAnnotationProcessorImpl.java:212)
         at weblogic.servlet.internal.WebAnnotationProcessorImpl.processAnnotations(WebAnnotationProcessorImpl.java:107)
         at weblogic.servlet.internal.WebAppServletContext.processAnnotations(WebAppServletContext.java:1287)
         at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:412)
         at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:456)
         at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:414)
         at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.java:910)
         at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:364)
         at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:42)
         at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
         at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191)
         at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:16)
         at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:155)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:197)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:89)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:723)
         at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1190)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:248)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:157)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:12)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:45)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    >Any help to resolve this would be appreciated!
    Thanks, Ken

    Olaf,
    Sorry I missed your blog post. It was helpful, but it did not allow me to successfully run my application on the standalone WebLogic 10.3. To do this, I did the following:
    1. Created ADF/ADF Faces web application - runs fine in integrated WebLogic Instance.
    2. Followed directions to setup standalone WebLogic Server as outlined in above posts with links to Duncan Mills and Chris Muir, including installation of latest JDeveloper ADF libraries.
    3. Copied adfmweb.jar, adfm.jar, adfdt_common.jar to .../domains/adf_domain/lib/ following setup by Chris Muir.
    4. In console in standalone WebLogic 10.3 server, create JDBC Data Source with name jdbc/whdp_DS (In the test, I got an error. At this point, I replaced the URL with the JDBC custom URL that I use in SQL Developer for this data set which is setup to connect to a RAC setup with failover. Works great. No error message on testing.)
    5. In META-INF, added application.xml and weblogic-application.xml as outlined in http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/deployment_topics.htm#insertedID7
    6. In WEB-INF, added weblogic.xml that is outlined in document referenced in step 5. Modified this file, adding the statements from Olaf's blog post.
    >
    <library-ref>
    <library-name>jstl</library-name>
    </library-ref>
    <library-ref>
    <library-name>jsf</library-name>
    </library-ref>
    >
    6b. Modifed web.xml, added resource-ref to jdbc/whdp_DS
    >
    <resource-ref>
    <res-ref-name>jdbc/whdp_DS</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
    </resource-ref>
    >
    7. In the application, modified the AppService defined in the model by right clicking on the AppService and selecting configuration. I changed both the local and shared configurations to use the jdbc DataSource jdbc/whdp_DS. I am not sure which one is needed to be changed, but changing them both made the application work on the standalone WebLogic 10.3 server.
    8. Deploy to standalone server. I had previously created the application server as a target.
    Now my deployment works, AND running the application works. The question now is whether this is the "best" way to do this, or is there an easier way. Also, what about developing locally? How do you manage both the data source defined for the standalone server and a simple JDBC URL for the integrated server? Couldn't find that explained in the docs anywhere.
    I also noticed that with the latest JDeveloper install (build 5205), there is now an extra entry about an UDDI server not running that isn't critical in the logs. This may be caused from the reinstall and not selected UDDI as an option for WebLogic components, but this message shouldn't appear.
    Thanks, Ken

  • How to remove/ignore the element using SAXParser

    hello all,
    I want to parse the text content in string from the existed xml file. but had problem with the parser. Does anyone have good idea, how to remove or ignore the <link> tag in tag <text>?
    IS: the output is only the rest of part text behind <link style="blue" src="www.test.com" />.
    Wanted: the whole text in <text> tags. like "Reach more customers by creating targeted micro-sites using test's multi-store retailing functionality."
    Given below is my code :
    <?xml version="1.0"?>
    <test xmlns="http://www.test.com/test">
    <title>test title</title>
    <text>Reach more customers by creating targeted micro-sites using test's<link style="blue" src="www.test.com" /> multi-store retailing functionality.</text>
    </test>java code using SAXParser
      public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
      public void endElement(String uri, String localName, String qName) throws SAXException {
        if (qName.equals("text")) {
          System.out.println("content: " + text);
      public void characters(char[] ch, int start, int length) throws SAXException {
        String str = new String(ch, start, length);
        if (str.length() > 0)
          text = text == null ? str : text + str;
    ...Edited by: lauehuang on Sep 9, 2008 4:37 AM

    i think u can't modify the xml file using SAX
    SAX is only for reading XML
    for any modifications in xml file u have to use DOM parser....
    correct me if i m wrong....
    Thanks & Regs
    Ravi

  • Change the default colours in line chart

    hi everyone,
    I'am a new user in Flex, and I am facing my first barrier
    I am using a code to interact a table and a graph
    the defaults colours of the lines are orange and a kind of green
    I would like to change these colours to red and pure green if it's possible
    here is my code
    <?xml version="1.0"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
    layout="absolute" width="600" height="600"
    creationComplete="init()" applicationComplete="stage.scaleMode = StageScaleMode.EXACT_FIT;">
    <mx:Script>
    <![CDATA[
    [Bindable] private var chartData:XML;
    private function init():void
    //Inject the JavaScript functions we need to interface with the RMA
    //You can find the scripts below in the "acroJSFunctions" string object
    ExternalInterface.call("eval", acroJSFunctions);
    //set up callback for upadtes
    //the format script in each of the fields uses callAS to send the field name and it's value to the RMA
    //the function for this callback then modifies the XML that drives the chart.
    ExternalInterface.addCallback("changeData", changeData);
    //set up callbacks for commenting
    ExternalInterface.addCallback( "multimedia_getState", getState );
    ExternalInterface.addCallback("multimedia_setState", setState);
    loadDefaultXML();
    private function loadDefaultXML():void
      var req:URLRequest = new URLRequest("defaultChartData.xml");
    var loader:URLLoader = new URLLoader(req);
    loader.addEventListener("complete", xmlLoaded);
    private function xmlLoaded(event:Event):void
        chartData = new XML(event.target.data);
        loadDataFromAcroFields();
    private function loadDataFromAcroFields():void
        //get the values from the PDF
        var c:int;
        var r:int;
        for (c=0;c<2;c++)
       for (r=0;r<16;r++)
          var result:String = ExternalInterface.call("getFieldValue",r, c);
          chartData.children()[r].children()[c] = int(result);
    private function changeData(name:String, value:String):void
    //this function gets called when the field value in the PDF file changes
    //look in the format script for the field in the PDF.
    //the field name is in the form "table.r.c" where r is the row number and c is the column.
    //So the first field in the table would be called "table.0.0"
    //By splitting the string into an array, I can modify the corresponding element in the XML object that drives the chart.
    var fieldNameArray:Array = name.split(".");
    var row:int = int(fieldNameArray[1]);
    var column:int = int(fieldNameArray[2]);
    var val:int = int(value);
    chartData.children()[row].children()[column] = val
    private function getState():String
    //store the chart data XML
    return chartData.toString();
    private function setState(stateData:String):Boolean
    chartData = new XML(stateData);
    var c:int;
    var r:int;
        for (c=0;c<2;c++)
       for (r=0;r<16;r++)
          var fieldVal:String = chartData.children()[r].children()[c].toString();
          var result:String = ExternalInterface.call("setFieldValue",r, c, fieldVal);
    return true;
    ]]>
    </mx:Script>
    <mx:String id="acroJSFunctions">
    <![CDATA[
    function getFieldValue(row, column)
        fieldName="table."+row+"."+column;
        fieldValue = this.getField(fieldName).value;
        return fieldValue;
    function setFieldValue(row, column, value)
        fieldName="table."+row+"."+column;
        this.getField(fieldName).value = value;
    ]]>
    </mx:String>
    <mx:SeriesInterpolate id="interpolateIn" duration="1000"/>
    <mx:Canvas backgroundColor="#FFFFFF" width="100%" height="100%" horizontalScrollPolicy="off" verticalScrollPolicy="off" borderStyle="solid" borderThickness="1" borderColor="#000000">
        <mx:LineChart id="chart" dataProvider="{chartData.totals}" showDataTips="true"
         left="10" top="10" right="10" bottom="10">
         <mx:horizontalAxis>
          <mx:CategoryAxis categoryField="Day"/>
      </mx:horizontalAxis>
      <mx:series>
       <mx:LineSeries yField="FY06" displayName="No. errors" showDataEffect="{interpolateIn}"/>
       <mx:LineSeries yField="FY07" displayName="No. lines" showDataEffect="{interpolateIn}"/>
      </mx:series>
    </mx:LineChart>
         <mx:Legend dataProvider="{chart}" right="25" bottom="25" borderStyle="outset"/>
    </mx:Canvas>    
    </mx:Application>
    I've tried to read this post: http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7c5c.html#WS2d b454920e96a9e51e63e3d11c0bf6568f-7ff5
    then I've tried to understand how can I modify and insert the following code to mine, I've tried but doesn't work
    <mx:series>
               <mx:LineSeries yField="profit" displayName="Profit">
                <mx:lineStroke>
                    <mx:SolidColorStroke
                        color="0x0099FF"
                        weight="20"
                        alpha=".2"/>
                </mx:lineStroke>               
               </mx:LineSeries>
               <mx:LineSeries yField="expenses" displayName="Expenses">
                <mx:lineStroke>
                    <mx:SolidColorStroke
                        color="0x0044EB"
                        weight="20"
                        alpha=".8"/>
                </mx:lineStroke>               
               </mx:LineSeries>
            </mx:series>
    can you please help me?
    thanks a lot
    Win 7 64 bits
    Adobe Flash Builder 4.6 Premium

    Well, I'm getting closer.  I have resorted the legend according to the order of the lines on the chart, by doing the following:
    > chart expert
    > data tab
    > select field from "On change of" list
    > Top N button
    > For this group sort "All", based on the same field as I selected from the "On Change of" list, in descending order
    > click OK and OK again.
    Although this worked, I'm pretty sure it's sorting on the wrong year.  I would like the legend to be sorted descending, according to the values in 2010, not 2006, which it appears to be doing.  Any ideas?
    By the way, my apologies if I mislead anyone by saying I have grouped charts.  It's actually an advanced report that is grouped by one of my data fields.  This produces a new chart for each group automatically.
    Thanks again.  I appreciate all offers of help!

  • Why can't  see the configArchive  directory in domain ?

    hi,everyone,
    I have constructed some wls domain such domain-a,domain-b,domain-c using the same configure wizard of wls8.1sp2,and
    found one strange thing:
    after running several weeks,within domain-a ,i found domian-a/configArchive directory ,but can't find it in
    domain-b and domain-c ,for all three domains, i have changed the domain config and setup the Administration Server
    archives up to 10 previous versions of config.xml(In the domain Configuration->General tab:Archive Configuration Count
    box,).
    according to WLS8.12 docuement ,when change the domain configuration, the wls server will backup configure.xml to
    domain-name/configArchive directory.
    My question is : why some domain don't create configArchive directory and others can do it automatic ? Need i
    create configArchive directory manually or do other things ?
    thanks a lot.
    Great Lou

    Gopal,thanks a lot.
    I am using weblogic8.1sp2 also. I just changed item "Enable SSL Port" ,and found that configArchive directory
    was created.
    This really made me confusing :My domains are running in product environment for long time,I had changed some
    domain configure to tuning performance ,some change made by directly edit config.xml,others made by weblogic
    console, but I can't see configArchive directory until today.
    Anyway ,now config.xml-backup works normal,Let it be...
    Great Lou
    On Wed, 8 Jun 2005 11:35:50 -0700, Gopal Allam <> wrote:
    Lou,
    Thats right. If the changes you do through weblogic console modifies config.xml, then config.xml should automatically be archived in configArchive directory.
    What version of weblogic you are on ? We are using weblogic 81sp2 which works as mentioned in the documentation.
    -Gopal

  • Debugging of ABAP Function Module through ISA Application CRM B2C 4.0

    Hi Experts
    There is way to Debug ABAP FM through ISA CRM b2c Application by Modifying some XML Files as per Extn Guide.
    I tried modifying the <APPLICATION_HOME>\WEB-INF\xcm\customer\modification\modification-config.xml After that I restarted the Application .
    But it is not Breaking for Both Statefull & Stateless FM after running my Application.
    With Some Help i found that if we try it on Remote System ( Means SAP GUI has to in Same System where CRM is Installed ???????????). but that is not Advisable Right !!!.
    So if i am able to Debug ABAP Function Module through ISA Application from any Other remote System.
    I think it will be very Useful.
    Thanks & Regards
    Ravi Sah

    Ravi
    It is other way around !!!
    You should have SAP GUI installed on the machine in which you start(access) your B2C Application. This enables for ABAP Debugging.
    We have tried this and works fine for us !!!
    Thanks
    Jack
    <b>Allot points if my post helps !!!</b>

  • RFQ and PO XSL-FO reports

    Hello All,
    We are currently implementing R12 (Sourcing, Purchasing etc) for one of the customer in APAC region, and we have to modify standard
    RFQ and PO XSL-FO reports. We are able to modify XSL files.
    But if we have to add new fields, we need to modify base XML file.
    1. In case of PO, we can modify inline views. But after modifying view, how to generate new XML file which in turn will show the new fields?
    2. In case of RFQ, we didn't find any in-line view.
    We need to understand the mechanism how it works and how to change base XML file for new fields?
    Please send-in your inputs/pointers.
    Regards
    Rohit

    For R12
    =====
    1. In case of PO, you can modify inline views.
    After this modification, PO xml file will contain newly added fields.
    Create your custom XSLFO template for PO and attached it to PO document.
    2. In case of RFQ, you need to modify 'PON_PRINTING_PKG' package to add new fields.
    After this modification, RFQ xml file will contain newly added fields.
    Create your custom XSLFO template for RFQ and attached it to RFQ document.
    Before doing this changes keep in mind that both solutions are not advisable because you are going to update standard views and packages.
    ~ MS
    Edited by: MS on Feb 8, 2011 9:11 PM

  • Catalog views for ERP E-Commerce for MySAP ERP ECC 5.0

    We are implementing the R/3 version of CRM-ISA (ERP E-Commerce for MySAP ERP ECC 5.0).
    We need to implement product catalog views to allow filtering based on specific attributes.
    We have created a custom function module Z_ISA_READ_CATALOG_COMPLETE to replace ISA_READ_CATALOG_COMPLETE and  Z_ISA_CUSTOMER_READ_CAT_VIEWS to replace ISA_CUSTOMER_READ_CAT_VIEWS.
    But when we test from ISA the FM Z_ISA_READ_CATALOG_COMPLETE does not get invoked through RFC.
    There is an  SAP NOTE 998453 that we checked but it is still a pilot version.
    Has anyone implemented the catalog views without the notes? Can we do the catalog views without the note? If so, how can we meke custom FM work? Please advice.
    Thanks,
    VK

    Check the following.
    1. The XCM file modification-config.xml replaces both the function modules
    2. The checkbox to use the catalog views is checked for your webshop
    3. Catalog is published to TREX and you are using TREX catalog instead of Memory catalog.
    I don't think these notes work without TREX. I'd be interested in learning if anyone successfully implemented Catalog views with ECC ECO without using TREX.
    - Kishore

  • Single .rar file for multiple data sources

    Can we configure multiple data sources into single .rar file? . Currently,
    we are creating a seperate .rar file to configure each datasource by
    'only' modifing ra.xml file. This is proving to be a tedius operation in
    some cases when the application is integrated with multiple data sources.

    Siva-
    Unfortunately, no. One of the limitations of the resource adapter spec
    is that it doesn't provide a means of specifying multiple separate named
    configurations, so you can only have a single configuration.
    If you need more flexibility, you may want to consider programatically
    building up the PersistenceManagerFactory and then binding them into
    JNDI.
    In article <cqscdo$n1o$[email protected]>, Siva wrote:
    Can we configure multiple data sources into single .rar file? . Currently,
    we are creating a seperate .rar file to configure each datasource by
    'only' modifing ra.xml file. This is proving to be a tedius operation in
    some cases when the application is integrated with multiple data sources.--
    Marc Prud'hommeaux
    SolarMetric Inc.

  • Internet Sales 4.0 RFC specific debugging problems

    Hi all!
    Has anyone succeeded in using the modification-config.xml file to debug a single given stateless RFC function set as a parameter to the following structure:
    <param name="jco.client.abap_debug.func" value=""/>
    We have succeeded in debugging all by just setting the following in place:
    <param name="jco.client.abap_debug" value="true"/>
    But if we try to debug a single RFC by specifying as per the documentation:
    <param name="jco.client.abap_debug.func" value="RFC_GET_FUNCTION_INTERFACE"/>
    The ABAP debugger does not get launched. We have tried this with a number of functions, in upper and lower case characters, etc. but this only seems to work if we choose to debug all the RFCs by leaving the value parameter empty.
    Again: Are we missing something here or is does this just not work? Could this have something to do with the JCO downgrade that SAP had us do for the SP6 release?

    Hi,
    The following threads could be of help:
    Re: Internet Sales 4.0 (R/3 Edition) & ECC 6.0
    Upgrading ECC5.0 to ECC6.0 and Internet Sales ISA4.0 CRM4.0
    The JCO settings need to be configured and pay special attention to the password issues (lowercase causes the login to fail)
    Regards,
    Srikishan

  • TOC built on import using XSLT

    Hello,
    I am working on a FM application which modifies the XML via preprocessing XSLT.
    This includes building a full TOC on the front matter which contains hyperlinks to all the top level chapter titles via unique id's @idref on the TOC/TOC-entry-1/TOC-ref element.
    However, when the front matter FM is generated, the structure view does not show the idref attribute and therefore an empty TOC.
    Is there a way of refreshing the .FM file somehow to reflect the new structure and show the TOC entries ?
    Thanks,
    Andy

    Van,
    As I have inherited this FM appliction, I do not want to change too much. My task was to simply change the page sizes within a particular template which I have done. The only thing I had to alter was the leader dot length, otherwise I altered nothing else.
    Everything is working OK apart from this top level TOC. It's part of a book where the XSL does modify the <TOC-ref> element to populate the idref attribute with the target id.
    Meanwhile, I ran the XSLT on it through Oxygen as you suggested, and the idref is certainly being populated as follows :
    <TOC-entry-1><TOC-ref idref = "D-GA-000047.1" format="TOC-1"/></TOC-entry-1>
    The target id is external.
    As mentioned the structure view does not show these attributes. Just TOC-ref followed by <WHITESPACE>.
    Apparently, according to the customer, this TOC did work before. The original app was compiled using FM8, and I have generated the new templates in FM10. I subsequently upgraded the Read/Write rules and the EDD to reflect FM10 thinking this may be the answer but still not working.
    OR, perhaps it's something to do with the XSLT parser version ? Does this need specifying or does FM use a standard version.
    I had to specifically set it to Saxon6.5.5 within Oxygen to get it working.
    Thanks,
    Andy

  • JCO Function Module Listener

    I have created a JCO Function Module Listener to be triggered after a BAPI in R/3 is called.
    I have made the following modifications to the modification-config.xml:
         <function-module-listener>
         <param name="fmevent:ZBAPISDORDER_GETDETAILEDLIST" value="com.xxx.listeners.ZBAPISDORDER_GETDETAILEDLIST_Listener" />
         </function-module-listener>
    The default BAPI implementation has been changed with a new BAPI. I have made the configuration changes to refer to the new BAPI and the new BAPI also is getting called. Should I register for Function Module listener to the Original one or to the modified BAPI name..
    When I execute this BAPI, the Function Module listener class is not getting called. I have a debug statement to write to the logs at the start of the "connectionEvent" method and seems this itself is not getting called.
    Should I register this class to be notified for events..
    Please letme know if there are any configuration to be made from the SAP side or from SAP J2EE Engine to get this done.
    Thanks & Regards,
    D.Vinodh

    Vinodh
    <b>Should I register for Function Module listener to the Original one or to the modified BAPI name..</b>
       --> I hope it should registered for Modified One !!!
    Thanks
    Jack
    Allot points if it helps !!!

  • Java.sql.SQLException: User: fusionEJB3, failed to be authenticated

    Dear experts,
    My intention was to call a pojo, (ProductCatalog) from a servlet (SimpleRestServlet) in order to query a db entity for products in xml form.
    The original thought was to be able to get the products via a servlet, but the entity manager is null:
    Thus, what I get is:
    Target URL -- http://localhost:7101/example8-1/products.jsp
    DoGet invoked on RESTful service.
    <Aug 22, 2011 7:12:09 AM GMT> <Error> <HTTP> <BEA-101020> <[ServletContext@335926353[app:chapter8 module:example8-1 path:/example8-1 spec-version:2.5]] Servlet failed with Exception
    java.lang.NullPointerException
         at com.soacookbook.ProductCatalog$beaVersion0_15.getAllProducts(ProductCatalog.java:38)
         at com.soacookbook.ProductCatalog.getAllProducts(ProductCatalog.java)
         at com.soacookbook.ProductCatalog.<init>(ProductCatalog.java:29)
         at com.soacookbook.web.SimpleRestServlet$beaVersion0_14.doGet(SimpleRestServlet.java:45)
         at com.soacookbook.web.SimpleRestServlet.doGet(SimpleRestServlet.java)
         Truncated. see log file for complete stacktrace
    However, if I create a stateless session bean, the generated java SE client is working well!
    I start with the error logs; the full code will follow.
    If i use the servlet to access the product entity I get:
    <Aug 21, 2011 1:48:07 PM GMT> <Alert> <EclipseLink> <BEA-2005000> <2011-08-21 13:48:07.826--ServerSession(2081428224)--Local Exception Stack:
    Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.1.3.v20110304-r9073): org.eclipse.persistence.exceptions.DatabaseException
    Internal Exception: java.sql.SQLException: User: fusionEJB3, failed to be authenticated.
    Error Code: 0
         at org.eclipse.persistence.exceptions.DatabaseException.sqlException(DatabaseException.java:309)
         at org.eclipse.persistence.sessions.JNDIConnector.connect(JNDIConnector.java:138)
         at org.eclipse.persistence.sessions.JNDIConnector.connect(JNDIConnector.java:94)
         at org.eclipse.persistence.sessions.DatasourceLogin.connectToDatasource(DatasourceLogin.java:162)
         at org.eclipse.persistence.internal.databaseaccess.DatasourceAccessor.connectInternal(DatasourceAccessor.java:327)
         at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.connectInternal(DatabaseAccessor.java:291)
         at org.eclipse.persistence.internal.databaseaccess.DatasourceAccessor.connect(DatasourceAccessor.java:415)
         at org.eclipse.persistence.sessions.server.ConnectionPool.buildConnection(ConnectionPool.java:155)
         at org.eclipse.persistence.sessions.server.ExternalConnectionPool.startUp(ExternalConnectionPool.java:118)
         at org.eclipse.persistence.sessions.server.ServerSession.connect(ServerSession.java:495)
         at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.login(DatabaseSessionImpl.java:627)
         at org.eclipse.persistence.internal.jpa.EntityManagerFactoryProvider.login(EntityManagerFactoryProvider.java:230)
         at org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.deploy(EntityManagerSetupImpl.java:389)
         at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.getServerSession(EntityManagerFactoryImpl.java:164)
         at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:221)
         at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:209)
         at com.soacookbook.ProductCatalog.getAllProducts(ProductCatalog.java:46)
         at com.soacookbook.ProductCatalog.<init>(ProductCatalog.java:27)
         at com.soacookbook.SimpleRestServlet.doGet(SimpleRestServlet.java:41)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    <?xml version="1.0" encoding="UTF-8" ?>
    <persistence xmlns="http://java.sun.com/xml/ns/persistence"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
    version="1.0">
    <persistence-unit name="example8-1">
    <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
    <!--jta-data-source>jdbc/fusionEJB3</jta-data-source>
    <non-jta-data-source>jdbc/fusionEJB3</non-jta-data-source-->
    <class>com.soacookbook.entities.Product</class>
    <properties>
    <property name="eclipselink.target-server" value="WebLogic_10"/>
    <property name="javax.persistence.jtaDataSource"
    value="jdbc/fusionEJB3"/>
    <property name="javax.persistence.jdbc.driver"
    value="oracle.jdbc.OracleDriver"/>
    <property name="javax.persistence.jdbc.url"
    value="jdbc:oracle:thin:@localhost:1521:orcl"/>
    <property name="javax.persistence.jdbc.user" value="fusionEJB3"/>
    <property name="javax.persistence.jdbc.password"
    value="57DAF0ADC12F7C37C6EC6D357C70ABD33754E34C120EB192D80F6E3B564BA6C8"/>
    <property name="eclipselink.logging.level" value="ALL"/>
    <property name="eclipselink.target-database" value="Oracle11"/>
    </properties>
    </persistence-unit>
    <persistence-unit name="JavaSEClient" transaction-type="RESOURCE_LOCAL">
    <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
    <class>com.soacookbook.entities.Product</class>
    <properties>
    <property name="eclipselink.target-server" value="WebLogic_10"/>
    <property name="eclipselink.target-database" value="Oracle"/>
    <property name="javax.persistence.jdbc.driver" value="oracle.jdbc.OracleDriver"/>
    <property name="javax.persistence.jdbc.password" value="fusionEJB3"/>
    <property name="javax.persistence.jdbc.user" value="fusionEJB3"/>
    <property name="eclipselink.logging.level" value="ALL"/>
    <property name="eclipselink.orm.validate.schema" value="true"/>
    <property name="javax.persistence.jdbc.url" value="jdbc:oracle:thin:@hera:1521:orcl"/>
    </properties>
    </persistence-unit>
    </persistence>
    package com.soacookbook;
    import com.soacookbook.entities.Product;
    import java.util.ArrayList;
    import java.util.Hashtable;
    import java.util.Iterator;
    import java.util.List;
    import javax.persistence.EntityManager;
    import javax.persistence.EntityManagerFactory;
    import javax.persistence.Persistence;
    import javax.persistence.Query;
    import javax.xml.bind.annotation.XmlRootElement;
    @XmlRootElement
    public class ProductCatalog {
    private EntityManager entityManager;
    private Hashtable emProps = new Hashtable();
    private List<Product> products;
    public ProductCatalog() {
    super();
    products= this.getAllProducts();
    public List<Product> getAllProducts(){
    EntityManagerFactory entityManagerFactory = Persistence.createEntityManagerFactory("example8-1");
    entityManager= entityManagerFactory.createEntityManager(emProps);
    Query query= entityManager.createNamedQuery("Product.findAll");
    System.out.println(" Results number: " + query.getMaxResults());
    return query.getResultList();
    public void setProducts(List<Product> products) {
    this.products = products;
    package com.soacookbook;
    import java.io.IOException;
    import javax.servlet.ServletConfig;
    import javax.servlet.ServletException;
    import javax.servlet.ServletOutputStream;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import javax.xml.bind.JAXBContext;
    import javax.xml.bind.JAXBException;
    import javax.xml.bind.Marshaller;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import javax.xml.transform.Source;
    import javax.xml.transform.Transformer;
    import javax.xml.transform.TransformerFactory;
    import javax.xml.transform.dom.DOMSource;
    import javax.xml.transform.stream.StreamResult;
    import org.w3c.dom.Document;
    public class SimpleRestServlet extends HttpServlet {
    private static final String CONTENT_TYPE = "text/xml; charset=UTF-8";
    private static final String DOC_TYPE = null;
    public void init(ServletConfig config) throws ServletException {
    super.init(config);
    public SimpleRestServlet() {
    super();
    protected void doGet(HttpServletRequest request,
    HttpServletResponse response) throws ServletException,
    IOException {
    System.out.println("DoGet invoked on RESTful service.");
    ProductCatalog catalog = new ProductCatalog();
    Source xmlSource = asXml(catalog);
    ServletOutputStream out = response.getOutputStream();
    response.setContentType("text/xml");
    StreamResult st = new StreamResult(out);
    try {
    Transformer t = TransformerFactory.newInstance().newTransformer();
    t.transform(xmlSource, st);
    } catch (Exception e) {
    throw new ServletException(e);
    System.out.println("All done.");
    private static Source asXml(ProductCatalog pc) throws ServletException {
    System.out.println("Marshalling...");
    Source source = null;
    Document doc = null;
    try {
    JAXBContext ctx = JAXBContext.newInstance(ProductCatalog.class);
    Marshaller m = ctx.createMarshaller();
    DocumentBuilder parser =
    DocumentBuilderFactory.newInstance().newDocumentBuilder();
    doc = parser.newDocument();
    System.out.println("Products=" + pc);
    m.marshal(pc, doc);
    System.out.println("Marshalled catalog to XML.");
    } catch (JAXBException je) {
    throw new ServletException(je);
    } catch (ParserConfigurationException pce) {
    throw new ServletException(pce);
    source = new DOMSource(doc);
    System.out.println("Returning XML source.");
    return source;
    protected void doPost(HttpServletRequest request,
    HttpServletResponse response) throws ServletException,
    IOException {
    doGet(request, response);
    package com.soacookbook.entities;
    import java.io.Serializable;
    import java.math.BigDecimal;
    import javax.persistence.Column;
    import javax.persistence.Entity;
    import javax.persistence.Id;
    import javax.persistence.NamedQueries;
    import javax.persistence.NamedQuery;
    import javax.xml.bind.annotation.XmlType;
    @XmlType
    @Entity
    @NamedQueries( { @NamedQuery(name = "Product.findAll",
    query = "select o from Product o") })
    public class Product implements Serializable {
    private String id;
    private String name;
    private BigDecimal price;
    public Product() {
    public Product(String id, String name, BigDecimal price) {
    this.id = id;
    this.name = name;
    this.price = price;
    @Id
    @Column(nullable = false)
    public String getId() {
    return id;
    public void setId(String id) {
    this.id = id;
    public String getName() {
    return name;
    public void setName(String name) {
    this.name = name;
    public BigDecimal getPrice() {
    return price;
    public void setPrice(BigDecimal price) {
    this.price = price;
    Finally, the perfectly working java SE client:
    package com.soacookbook.client;
    import com.soacookbook.ProductCatalog;
    import com.soacookbook.entities.Product;
    import java.util.ArrayList;
    import java.util.Hashtable;
    import java.util.Iterator;
    import java.util.List;
    import javax.persistence.EntityManager;
    import javax.persistence.EntityManagerFactory;
    import javax.persistence.Persistence;
    import javax.persistence.Query;
    public class ProductCatalogSEClient {
    private EntityManager entityManager;
    private Hashtable emProps = new Hashtable();
    public ProductCatalogSEClient() {
    super();
    public static void main(String[] args) {
    ProductCatalogSEClient productCatalogSEClient = new ProductCatalogSEClient();
    List<Product> products = productCatalogSEClient.getAllProducts();
    Iterator i = products.iterator();
    while (i.hasNext())
    Product product = (Product) i.next();
    System.out.println("Id:"+ product.getId() +" Name:"+product.getName() + " price " + product.getPrice());
    public List<Product> getAllProducts(){
    EntityManagerFactory entityManagerFactory = Persistence.createEntityManagerFactory("JavaSEClient");// not the same with example8-1 !
    entityManager= entityManagerFactory.createEntityManager(emProps);
    Query query= entityManager.createNamedQuery("Product.findAll");
    System.out.println(" Results number: " + query.getMaxResults());
    return query.getResultList();
    Thanks in advance for any help!
    NA
    Edited by: NA on Aug 22, 2011 10:56 AM

    Thank you for your reply!
    It ran successfully having the following modifications:
    <?xml version="1.0" encoding="UTF-8" ?>
    <persistence xmlns="http://java.sun.com/xml/ns/persistence"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
    version="1.0">
    <persistence-unit name="example8-1">
    <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
    <jta-data-source>jdbc/fusionEJB3</jta-data-source>
    <class>com.soacookbook.entities.Product</class>
    <properties>
    <property name="eclipselink.target-server" value="WebLogic_10"/>
    <property name="eclipselink.target-database" value="Oracle"/>
    <property name="eclipselink.logging.level" value="ALL"/>
    </properties>
    </persistence-unit>
    <persistence-unit name="JavaSEClient" transaction-type="RESOURCE_LOCAL">
    <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
    <class>com.soacookbook.entities.Product</class>
    <properties>
    <property name="eclipselink.target-server" value="WebLogic_10"/>
    <property name="eclipselink.target-database" value="Oracle"/>
    <property name="javax.persistence.jdbc.driver" value="oracle.jdbc.OracleDriver"/>
    <property name="javax.persistence.jdbc.password" value="fusionEJB3"/>
    <property name="javax.persistence.jdbc.user" value="fusionEJB3"/>
    <property name="eclipselink.logging.level" value="ALL"/>
    <property name="eclipselink.orm.validate.schema" value="true"/>
    <property name="javax.persistence.jdbc.url" value="jdbc:oracle:thin:@hera:1521:orcl"/>
    </properties>
    </persistence-unit>
    </persistence>
    Strangely, the password string fusionEJB3, however changed to:
    <property name="javax.persistence.jdbc.password"
    value="57DAF0ADC12F7C37C6EC6D357C70ABD33754E34C120EB192D80F6E3B564BA6C8"/>
    Edited by: NA on Aug 23, 2011 9:48 AM

  • Service Request FM, CRM_ICSS_SRVREQ_CREATE

    Hi All,
    Did anyone worked on FM CRM_ICSS_SRVREQ_CREATE ?.. I Tried the same in a simple report and able to create a transaction, and one item as well..
    Now, If want to create multiple Items Is it possible to use this FM ?.. The data of items is passed to the FM as a Local Structure ( Not Internal table ) so I think I can create only one Item for one Service Request via this FM !..
    Is this correct ??.. Is it possible to achieve via same FM ?.. or else should I try some other FM ?..
    Please Help..
    Any Help / Hint will be appreciated,,
    Many Thanks in Advance, Sudeep..

    Hi Anil,
    You can find the modification-config.xml file in the below DC.
    sap.com_SAP-SHRWEB_1->DC->crm/tc/web/core
    NWDS(after creating project on this)
    crmtcwebcore~sap.com/src/packages/WEB-INF/xcm/customer/modification/modification-config.xml
    I hope this helps.
    Regards,
    Senthil.

Maybe you are looking for