Additional attributes (such as "xmlns:xsi") in document

How can I add some additional attributes in in my toplevel element when creating
a new XML document from scratch using XMLBeans. For example the attributes "xmlns:xsi"
and "xsi:schemaLocation" in the sample below:
<?xml version="1.0" encoding="UTF-8"?>
<MyDoc xmlns="http://www.xxx.nl/yyy" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.xxx.nl/yyy myXsd.xsd">
<..../>
<..../>
</MyDoc>
XML does add the "xmlns" attribute itself. How can I add the two other attributes?
Currently I have a workaround. I read an "empty" XML-file containing these attributes
using XMLBeans (parse) and then I fill the empty structure. But I feel that there
has to be a better solution. Unfortunately I cannot find it.
Any help is appreciated. Thank you in advance.

Hello Olaf -- You might trying using an XML cursor. So assuming you've
compiled a schema to generate XMLBeans types, you might do something like
the following.
MyDocDocument myDocDoc = MyDocDocument.Factory.newInstance();
MyDoc myDoc = MyDocDocument.getMyDoc();
// Create a cursor and move it to where you want to start inserting
attributes.
XmlCursor cursor = myDoc.newCursor();
cursor.toFirstContentToken();
cursor.toLastAttribute();
// Insert your attributes.
cursor.insertAttributeWithValue("schemaLocation","http://www.w3.com/2001/XML
Schema-instance", "http://www.xxx.nl/yyy myXsd.xsd");
// ...add other attributes in a similar way...
// Dispose of the cursor.
cursor.dispose();
Without a schema, you'd be working with the XmlObject returned from your
newInstance or parse method.
Steve
"Olaf Wienk" <[email protected]> wrote in message
news:4029ee05$[email protected]..
>
How can I add some additional attributes in in my toplevel element whencreating
a new XML document from scratch using XMLBeans. For example the attributes"xmlns:xsi"
and "xsi:schemaLocation" in the sample below:
<?xml version="1.0" encoding="UTF-8"?>
<MyDoc xmlns="http://www.xxx.nl/yyy"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.xxx.nl/yyy myXsd.xsd">
<..../>
<..../>
</MyDoc>
XML does add the "xmlns" attribute itself. How can I add the two otherattributes?
>
Currently I have a workaround. I read an "empty" XML-file containing theseattributes
using XMLBeans (parse) and then I fill the empty structure. But I feelthat there
has to be a better solution. Unfortunately I cannot find it.
Any help is appreciated. Thank you in advance.

Similar Messages

  • Qualification Catalog Additional Attributes OOQA

    Is there a method to provided additional attributes on a qualification within the catalog? It appears that the text description is our only option.
    We would like to have some additional attributes, such as a link to a web page of our regulation standards for the individual qualifications.

    Hi Michael,
    You're right, when you implement additional attributes on the TREX, the value of the attributes is broken into parts, where each part contains not more than 64 characters, which are separated by a special character( in between them.
    This can be eliminated by the implementation of an SNote - 1005135 - Replication problems when pcat text exceeds 128 characters.
    However, as Sateesh has rightly said, maintaining each additional attribute as an additional text type in the PCAT_ITM or PCAT_HDR text objects is a better solution in terms of data maintenance and consistency. Further, you must plan the introduction of these additional attributes, as each addition would require an initial replication of the product catalog.
    Hope this helps.
    Thanks & Regards,
    Nelson S Raj

  • How to get attribute, such as Title, of Documents stored in WWDOC_DOCUMENT$

    Hi,
    I've created a portlet which reads from the WWDOC_DOCUMENT$ table and creates links to certain documents. However only the original filename and the Portal assigned numerical filename are stored within this table. I would like to be able to display the item title to users which was specified when the file was originally uploaded.
    Presumably somewhere there is another table which holds other attributes such as an items title, which is linked to WWDOC_DOCUMENT$ via a primary/foreign key.
    Can anyone help as to where this is?
    Thanks in advance.
    Dan

    pvujic wrote:
    Thanks, but how can I "fetch" the url from the image element?You've got to first get to the image element. But based on what you've posted though, with a little more coding, you should be able to succeed. Just give it a try! :)

  • How to include validation attribute (xmlns:xsi) into the resulting XML ?

    Hi,
    I'm having a problem including the validation schema attribute (xmlns:xsi) into the resulting XML.
    For example, if I have the following schema:
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    elementFormDefault="qualified">
    <xs:element name="A" />
    </xs:schema>
    And I use the following code to get the XML:
    XmlOptions ops = new XmlOptions();
    ADocument ad = ADocument.Factory.newInstance();
    ADocument.A a = ad.addNewSubscriptionNotification();
    System.out.println(ad.xmlText(ops));
    I will get something like:
    <A />
    I'd like to have:
    <A xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://a.com/a.xsd"/>
    How do I make this happen? Some xmlOptions, different kind of schema...?

    Use
                 <fx:resources>
                    <fx:fileset dir="${basedir}/${dist.dir}" includes="*.jar"/>
                    <fx:fileset dir="${basedir}/${dist.dir}" includes="lib/*.jar"/>
                </fx:resources>or simply
          <fx:fileset dir="${basedir}/${dist.dir}" includes="**/*.jar"/>Filed http://javafx-jira.kenai.com/browse/RT-24757 to update the docs.
    Edited by: igor on Sep 5, 2012 2:23 PM

  • Internet Sales Order - Additional attributes

    Hi,
    I have a requirement to enable Certification Requirements for products being sold.  Process goes like this -
    Customer places a Sales Order on Internet via Internet Sales Solution.  While placing the order, customer would select the types of certifications required for the product for example: certificate on country of origin, Quality certificate etc.  User should be able to select multiple such certificates as required, while creating the Sales Order.  Is there any way I can achieve this?  I am thinking about using additional attributes (via Set Types and attributes) assigned to the product master.  But, by assigning these to the product master, can I see the same attirbutes in the Sales Order in Internet Sales?  Secondly, can these attributes (with values) be transferred back to R/3 Sales Order? Any suggestions will be appreciated and properly rewarded for good answers.
    Thanks in advance

    Hi Gopala,
    Yes. You can use additional products attributes to display the required certification parameters.
    But these attributes can't be transfered onto the sales order by default. You need to some java development / abap development to extend the sales order.
    If you want to transfer the same attributes to R/3 order then you have enhance the BAPIMATICS strucuture so that the middleware transfers them.
    Also you need to extend R/3 sales order to hold these attributes. This is a complex scenario and you need to design a good functional specification document before even attempting the design
    Let me know, if you need any further info.
    <b>
    Do not forget to reward if it helps,</b>
    Regards,
    Paul Kondaveeti

  • Additional attributes for requester and approver

    Hi,
    I have a scenario:
    1.Requester should raise the request to assign the role for beneficiary and requester should select 'Valid from' and 'valid till' (valid from and valid till are additonal attributes)
    2. Approver will reivew the request and should be able to change the 'valid from' and 'valid till' dates ( role active dates )
    I have changed the 'AssignRolesDataset.xml' to display the additionals attributes for approver task by making 'approver-only'.
    Can I add addtionals attributes for requester ? Can the requester additional attributes values will visible to approver to review and change?
    These Additional attributes stores in which table?
    Can any one Please guide me here.
    Thanks
    gr

    Hi,
    I have created the 'AssignRolesDataset.xml' as below and imported successfully in oim (purged also), but not able to see the additonal attributes when I raise the request from self service and select the 'Assign Roles' , also not able to see the attributes with approver.
    AssignRolesDataset.xml
    <request-data-set xmlns="http://www.oracle.com/schema/oim/request" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.oracle.com/schema/oim/request" name="AssignRolesDataset" entity="Role" operation="ASSIGN">
    <DataSetValidator name="CreateUserDataValidator" classname="oracle.iam.requestactions.plugins.datavalidator.CreateUserDataValidator"/>
    <AttributeReference name="RoleActiveFrom" attr-ref="RoleActiveFrom" type="Date" length="30" widget="date" read-only="true"/>
    <AttributeReference name="RoleActiveTo" attr-ref="RoleActiveTo" type="Date" length="30" widget="date" required="true"/>
    </request-data-set>
    Please correct me here.
    Thanks
    Gr

  • Hello Apple community... I am trying to combine multiple pdf's into one, using preview, but when I drag the additional pages they show up as separate documents.

    I am trying to combine multiple pdf's into one, using preview, but when I drag the additional pages they show up as separate documents.  When I drag the doc in a line would show up in the past, and if I went above th eline all was good.  It doesn't have a line, and no matter what I try I am having no success.
    Please help!

    According to an Apple Support article, unless there are unforeseen issues
    in file ownership or permissions, the combining of .PDFs should be simple.
    •OS X: Combining PDF documents using Preview - Apple Support
    There are a few variable and similar methods, some change with version
    of OS X in use; some vintage OS X may vary a little in the process...
    A variety of similar topics appear in search results, with terms:
    " mac os x combine pdf into one " such as this page shows...
    https://www.google.com/?gws_rd=ssl#q=mac%20os%20x%20combine%20pdf%20into%20one
    If the system is older than Mavericks there may be other methods to try.
    Suggestions are among linked results in the search. I see a few fair ones.
    •Here's another that offers generally similar suggestions...*  this info looks OK, extra links, do not:
    http://osxdaily.com/2014/06/27/how-to-join-multiple-pdf-files-into-a-single-pdf- document-in-mac-os-x/
    { note: avoid clicking on links to products in * this ^ page, since they likely will not help & may be adware prone }
    If you have a problem after trying other methods, based on an OS X
    your computer is running, post back with more exact information...
    Good luck & happy computing!
    edited

  • Additional Attributes in AS2 Header using Seeburger Adapter

    Hello,
    our business partner required that we include some additional attributes in the AS2 mime header that are used for internal routing purposes (in addition to the AS2 ID).
    Attributes for example include a submissionType etc. Is it somehow possible to add this attributes? According to the documentation I can only add dynamicAttributes for standard fields, such as content type etc.
    Thank you for your support.
    Edited by: Florian Guppenberger on Oct 6, 2009 7:14 PM

    Hi,
    I think you can.. but not recommended to modify standard Adapters.
    Check the below blog.
    http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417500)ID0328214750DB00705897531357746266End?blog=/pub/wlg/4645
    Why dont you use Message subject or Content type ?
    Thanks
    Deepthi.

  • Extending Role Object with additional attributes

    All,
    I understand that there are 5 attributes available for the Object type as displayed in the 'object' table in the Sun IdM DB repository. As such, i would like to add to the Role object a couple of primitive type attributes. I would appreciate if anyone who has done this or has the knowledge do this would tell me how and where i can go about configuring the role object to have additional attributes besides the 'name' attribute. Thank you.

    Wilfred,
    we are trying out IDM 8.0 and release notes and administration guide for that version says that you can
    extend attributes for Roles in IDM Schema Configuration Object.
    But, documentation only specifies how to add a User extended attrbute, we tried adding
    an attribute called escalators in the following way:
    <IDMObjectClassConfiguration name='Role' extends='Object' displayName='UI_OBJECTCLASS_ROLE' description='Role description'>
    <IDMObjectClassAttributeConfiguration name='escalators' queryable='true' summary='true'/>
    </IDMObjectClassConfiguration>
    we then modified Role Form.xml object and added the following for testing purposes:
    <Field name='escalators'>
    <Display class='MultiSelect'>
    <Property name='title' value='Escalators'/>
    <Property name='availableTitle' value='UI_ROLES_XML_AVAILABLE_OWNERS_LABEL'/>
    <Property name='selectedTitle' value='UI_ROLES_XML_CURRENT_OWNERS_LABEL'/>
    <Property name='allowedValues'>
    <List>
    <String>roleapprover</String>
    <String>approver1</String>
    </List>
    </Property>
    </Display>
    </Field>
    but the value in the Multiselect just goes to /dev/null....
    Can you help us with describing how to add an extended role attribute for IDM 8.0
    Thank you in advance

  • CF MX inserting xmlns:xsi into my WSDL

    CF MX is over-riding my WSDL definitions.  Where I have:
    <wsdl:types>
    <s:schema elementFormDefault="qualified" targetNamespace="http://developer.intuit.com/">
    <s:element name="serverVersion">
    </s:element>
            <s:element name="serverVersionResponse">
            <s:complexType>
                <s:sequence>
                    <s:element minOccurs="1" maxOccurs="1" name="serverVersionResult" type="s:string" />
                  </s:sequence>
            </s:complexType>
    </s:element>
    The Service Call results in:
    <?xml version="1.0" encoding="utf-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <soapenv:Body>
      <ns1:serverVersionResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://qbwc.opensource">
       <serverVersionReturn xsi:type="xsd:string">Testing</serverVersionReturn>
      </ns1:serverVersionResponse>
    </soapenv:Body>
    </soapenv:Envelope>
    What is going on???

    Hi Again
    I have more info on the issue...
    I tried to reach the the webservice from OAS/HTTP with mod_plsql directly. At first I was not able to.
    A firewall request was completed and now I am sure the http server can reach the webservice in question.
    Unfortunatley creating a webservice either manually or through a wsdl is still not working! Please Help , what else can I check.
    Also
    I'm confused ..taken from APEX 4.0 online documenation
    SOAP offers two primary advantages:
    SOAP is based on XML, and therefore easy to use.
    SOAP messages are not blocked by firewalls because this protocol uses simple transport protocols, such as HTTP.
    I can't see why it would be a firewall issue based on the statement above.
    Thanks Again
    Moe
    -- just added to my post. Issue still unresolved
    I'vw been trying to troubleshoot it myself.
    From my database server -
    I'm not able to use utl_http - example
    set serveroutput on
    DECLARE
    req utl_http.req;
    resp utl_http.resp;
    value VARCHAR2(32000);
    BEGIN
    req := utl_http.begin_request('http://www.psoug.org');
    resp := utl_http.get_response(req);
    value := utl_http.request('http://www.psoug.org/');
    dbms_output.put_line(value);
    utl_http.end_response(resp);
    EXCEPTION
    WHEN utl_http.end_of_body THEN
    utl_http.end_response(resp);
    END;
    error received is
    ERROR at line 1:
    ORA-29273: HTTP request failed
    ORA-06512: at "SYS.UTL_HTTP", line 1130
    ORA-12535: TNS:operation timed out
    ORA-06512: at line 6
    Using ping
    ping www.psoug.orgPING 66.221.222.85: 64 byte packets
    ----66.221.222.85 PING Statistics----
    16 packets transmitted, 0 packets received, 100% packet loss
    However I'm confused if I'm using Oracle Application Server 10g Release 3 (10.1.3.1)/Apache
    Should I need to modify the firewall on the database side to access a webservice? Does it need to be port 80?
    Getting frustrated by my ignorance
    Thanks
    Moe
    Edited by: user570478 on Jul 28, 2011 2:23 PM

  • Along with Namespace require others atr like xmlns:xsi & xsi:schemaLocation

    Hi Experts,
    Could you please help me in creation of the XSD so that the output file from PI will contain the following message:
    Message xmlns="http://www.abc.com/schemas/" xmlns:xsi="http://www.w3.org/Schema-instance" xsi_schemaLocation="http://www.abc.com/schemas/ http://www.abc.com/schemas/4.0.0/2001/message.xsd" >

    Hi Experts,
    As i said  my requirement is to include the following in the output XML.
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation =="http://www.XYZ.com/schemas/ http://www.XYZ.com/schemas/4.0.0/2001/message.xsd">
    i have written the XSD as below
    <?xml version="1.0" encoding="UTF-8"?>
    <xsd:schema targetNamespace="http://www.XYZ.com/schemas/"
         xmlns="http://www.XYZ.com/schemas/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns:xsd="http://www.w3.org/2001/XMLSchema"
         xsi:schemaLocation="http://www.XYZ.com/schemas/ http://www.XYZ.com/schemas/4.0.0/2001/message.xsd">
         <xsd:element name="Message" type="Message" />
         <xsd:complexType name="Message">
              <xsd:sequence>
                   <xsd:element name="Head">
                        <xsd:complexType>
                             <xsd:sequence>
                                  <xsd:element name="field1">
                                       <xsd:complexType>
                                            <xsd:attribute name="Id" type="xsd:string" />
                                       </xsd:complexType>
                                  </xsd:element>
                             </xsd:sequence>
                        </xsd:complexType>
                   </xsd:element>
              </xsd:sequence>
         </xsd:complexType>
    </xsd:schema>
    but when  the correponding XML from this XSD donot have the
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation =="http://www.XYZ.com/schemas/ http://www.XYZ.com/schemas/4.0.0/2001/message.xsd">
    Any clue , how to handle this.

  • Unsupported action attribute value 'EXCECUTE' found in XML document

    Hi
    I am working on IDOC->XI->DB2 scenairo
    I am getitng error following error whe i try to insert and execute the stored procedure.
    Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Unsupported action attribute value 'EXCECUTE' found in XML document
    Following is the payload....
      <?xml version="1.0" encoding="UTF-8" ?>
    - <I805_Abstr_CustOutlet_MT>
    - <StatementInsert>
    - <STATUS action="INSERT">
      <table>BI5FILMM.BSOMSAPP</table>
    - <access>
      <OUTLET_NO>12</OUTLET_NO>
      <OUTLET_RF>20</OUTLET_RF>
      <OMFUNC>CRT</OMFUNC>
      <STATUS>N</STATUS>
      <IFCEDATE>1080626</IFCEDATE>
      <IFCETIME>094220</IFCETIME>
      </access>
      </STATUS>
      </StatementInsert>
    - <StatementProce>
    - <STATUS action="EXCECUTE">
      <table>CC5PTF.BSOMPSAP</table>
      <Para1 IsInput="true" type="CHAR">BI5FILMM</Para1>
      <Para2 IsInput="true" type="CHAR">BMIJOBD</Para2>
      </STATUS>
      </StatementProce>
      </I805_Abstr_CustOutlet_MT>

    Check ur XML format with the one mentioned in this
    http://help.sap.com/saphelp_nw2004s/helpdata/en/4d/8c103e05df2e4b95cbcc68fed61705/content.htm

  • Hi there, I currently subscribe to Adobe Pro Subscription (yearly) and I also subscribe to Adobe PDF pack (monthly).  I only require Adobe to read and create PDF documents such as converting word/excel document or a web based document.  Can someone tell m

    Hi there, I currently subscribe to Adobe Pro Subscription (yearly) and I also subscribe to Adobe PDF pack (monthly).  I only require Adobe to read and create PDF documents such as converting word/excel document or a web based document.  Can someone tell me if I'm doubling up as I'm not sure of the differences between the products and would like to save a few dollars.

    Acrobat Pro can do a lot more than the PDF Pack online service.
    Try if you can do everything you need with PDF Pack; otherwise keep Acrobat Pro.

  • Additional Attributes in Mail Forms

    Hi
    I want to create mail form templates and want to add some custom attributes in the additional attributes category of attributes and then write my own logic for filling up the values in those additional attributes at runtime.
    What are the structures and BADIs I need to enhance in order to do this?
    Thanks in advance
    Vishal

    Hi,
    Check if below helps you (Maintain Attribute Contexts for Mail Forms)
    SPRO->Customer Relationship Management->Marketing->Marketing Planning and Campaign Management->Personalized Mail->Maintain Attribute Contexts for Mail Forms.
    Just go through the SPRO documentation for same, it might help you.
    Regards,
    Dipesh.

  • Add Additional Attributes/Metadata to a Question to Enable Deeper Segmentation Analysis?

    In Captivate, is it possible to add additional attributes/metadata to a quiz question, to allow for more flexible and effective reporting?  For example, I want to categorize questions in two different buckets: Difficulty (Easy, Medium and Difficult) and Concept/Subject (Math, Verbal and Science etc..).
    That way, I can analyze a students performance by not only their aggregate score, but also where their strenghts and weaknesses lie - if I see that a student is struggling with all Easy Math questions, I'll know what to focus on during our next lesson?
    Any assistance would be much appreciated.

    Hi,
    We can create Question Pools with Questions of different difficulty level called directly to the slides.
    But this would not give the advantage on LMS end, this would simply filter questions and would present them in the order you like, attaching meta data to a specific question would not be possible from Captivate, neither would you be able to call it on LMS report directly. You can assign a unique Interaction ID to each question item though capture the questions corresponding to the ids. If you LMS can refine the resuklts based upon the pre-assigned id, that should be great.
    Meanwhile, this would be in a different line, but have you checked the pre-test quiz, can that fit somehow, in you requirements?
    http://help.adobe.com/en_US/captivate/cp/using/WS6029a80579ffffcd5a87e66f135bd55f8cc-7ffc. html
    Thanks,
    Anjaneai

Maybe you are looking for