How to get attribute from xml file

I managed to grab all the info from xml, except the "url" attribute in <image type="poster" url="" size="mid" .../>. Any ideas?
import java.io.*;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.net.*;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.NodeList;
import org.xml.sax.SAXException;
public class XmlParser {
     ArrayList<Movie> myMovies;
     Document dom;
     public XmlParser(){
          //create a list to hold the movie objects
          myMovies = new ArrayList<Movie>();
     public void runExample(String adr, String tagName) {
          parseXmlFile(adr);
          parseDocument(tagName);
          printData();          
     private void parseXmlFile(String adr){
          //get the factory
          DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
          try {               
               //Using factory get an instance of document builder
               DocumentBuilder db = dbf.newDocumentBuilder();
               //parse using builder to get DOM representation of the XML file
               URL xmlUrl = new URL(adr);
               InputStream in = xmlUrl.openStream();
               dom = db.parse(in);               
          }catch(ParserConfigurationException pce) {
               pce.printStackTrace();
          }catch(SAXException se) {
               se.printStackTrace();
          }catch(IOException ioe) {
               ioe.printStackTrace();
     private void parseDocument(String tagName){
          //get the root elememt
          Element docEle = dom.getDocumentElement();
          //get a nodelist of <movie> elements
          NodeList nl = docEle.getElementsByTagName(tagName);
          if(nl != null && nl.getLength() > 0) {
               for(int i = 0 ; i < nl.getLength();i++) {
                    //get the movie element
                    Element el = (Element)nl.item(i);
                    //get the Movie object
                    Movie mov = getMovie(el);
                    //add it to list
                    myMovies.add(mov);
      * I take an movie element and read the values in, create
      * an Movie object and return it
      * @param movE
      * @return
     private Movie getMovie(Element movE) {
          String title = getTextValue(movE, "original_name");
          String year = getTextValue(movE, "released");
          String imdbId = getTextValue(movE, "imdb_id");
          double score = getDoubleValue(movE, "score");
          String overview = getTextValue(movE, "overview");
          String poster = movE.getAttribute("url");
          Movie mov = new Movie(title, year, imdbId, score, overview, poster);
          return mov;
     private String getTextValue(Element ele, String tagName) {
          String textVal = null;
          NodeList nl = ele.getElementsByTagName(tagName);
          if(nl != null && nl.getLength() > 0) {
               Element el = (Element)nl.item(0);
               textVal = el.getFirstChild().getNodeValue();
          return textVal;
      * Calls getTextValue and returns a int value
      * @param ele
      * @param tagName
      * @return int
     private int getIntValue(Element ele, String tagName) {
          //in production application you would catch the exception
          return Integer.parseInt(getTextValue(ele, tagName));
      * Calls getTextValue and returns a double value
      * @param ele
      * @param tagName
      * @return double
     private double getDoubleValue(Element ele, String tagName) {
          return Double.parseDouble(getTextValue(ele, tagName));
      * Iterate through the list and print the
      * content to console
     private void printData(){
          System.out.println("Total Movies: " + myMovies.size());
          Iterator it = myMovies.iterator();
          while(it.hasNext()) {
               System.out.println(it.next().toString());
     public static void main(String[] args){
          //create an instance
          XmlParser xp = new XmlParser();
          //call run example
          xp.runExample("http://api.themoviedb.org/2.1/Movie.search/en/xml/apikey/Fight+Club+1999", "movie");
}Here is the example xml file I used
<?xml version="1.0" encoding="UTF-8"?>
<OpenSearchDescription xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/">
  <opensearch:Query searchTerms="Fight Club 1999"/>
  <opensearch:totalResults>1</opensearch:totalResults>
  <movies>
    <movie>
      <score>8.383284</score>
      <popularity>3</popularity>
      <translated>true</translated>
      <adult>false</adult>
      <language>en</language>
      <original_name>Fight Club</original_name>
      <name>Fight Club</name>
      <alternative_name>El Club de la Lucha</alternative_name>
      <type>movie</type>
      <id>550</id>
      <imdb_id>tt0137523</imdb_id>
      <url>http://www.themoviedb.org/movie/550</url>
      <votes>62</votes>
      <rating>8.4</rating>
      <certification></certification>
      <overview>A lonely, isolated thirty-something young professional seeks an escape from his mundane existence with the help of a devious soap salesman. They find their release from the prison of reality through underground fight clubs, where men can be what the world now denies them. Their boxing matches and harmless pranks soon lead to an out-of-control spiral towards oblivion.</overview>
      <released>1999-09-16</released>
      <images>
        <image type="poster" url="http://hwcdn.themoviedb.org/posters/f75/4bc908ab017a3c57fe002f75/fight-club-original.jpg" size="original" width="1000" height="1500" id="4bc908ab017a3c57fe002f75"/>
        <image type="poster" url="http://hwcdn.themoviedb.org/posters/f75/4bc908ab017a3c57fe002f75/fight-club-mid.jpg" size="mid" width="500" height="750" id="4bc908ab017a3c57fe002f75"/>
        <image type="poster" url="http://hwcdn.themoviedb.org/posters/f75/4bc908ab017a3c57fe002f75/fight-club-cover.jpg" size="cover" width="185" height="278" id="4bc908ab017a3c57fe002f75"/>
        <image type="poster" url="http://hwcdn.themoviedb.org/posters/f75/4bc908ab017a3c57fe002f75/fight-club-thumb.jpg" size="thumb" width="92" height="138" id="4bc908ab017a3c57fe002f75"/>
        <image type="backdrop" url="http://hwcdn.themoviedb.org/backdrops/f71/4bc908ab017a3c57fe002f71/fight-club-original.jpg" size="original" width="1280" height="720" id="4bc908ab017a3c57fe002f71"/>
        <image type="backdrop" url="http://hwcdn.themoviedb.org/backdrops/f71/4bc908ab017a3c57fe002f71/fight-club-poster.jpg" size="poster" width="780" height="439" id="4bc908ab017a3c57fe002f71"/>
        <image type="backdrop" url="http://hwcdn.themoviedb.org/backdrops/f71/4bc908ab017a3c57fe002f71/fight-club-thumb.jpg" size="thumb" width="300" height="169" id="4bc908ab017a3c57fe002f71"/>
      </images>
      <version>73</version>
      <last_modified_at>2010-09-11 14:33:06</last_modified_at>
    </movie>
  </movies>
</OpenSearchDescription>

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! :)

Similar Messages

  • How to get data from XML file having korea Text

    I have a one XML File with Korean Text, How to read this File.
    i tried with this code
    BufferedReader in = new BufferedReader(
    new InputStreamReader(new FileInputStream("C:/test1.xml"), "EUC-KR"));
    String str = in.readLine();
    but it is giving exceptions.
    please suggest me, how to retrive EUC-KR text from the XML file

    Standard Java does not support this Charset. You have to find a charset provider that implements "EUC-KR". But you should also consider using Unicode, which is implemented in standard Java.
    http://www.unicode.org/charts/

  • How to retrieve value from xml file

    hi all,
    can somebody pls tell me how to retrieve value from xml file using SAXParser.
    I want to retrieve value of only one tag and have to perform some validation with that value.
    it's urgent .
    pls help me out
    thnx in adv.
    ritu

    hi shanu,
    the pbm is solved, now i m able to access XXX no. in action class & i m able to validate it. The only thing which i want to know is it ok to declare static ArrayList as i have done in this code. i mean will it affect the performance or functionality of the system.
    pls have a look at the following code snippet.
    public class XMLValidator {
    static ArrayList strXXX = new ArrayList();
    public void validate(){
    factory.setValidating(true);
    parser = factory.newSAXParser();
    //all factory code is here only
    parser.parse(xmlURI, new XMLErrorHandler());     
    public void setXXX(String pstrXXX){          
    strUpn.add(pstrXXX);
    public ArrayList getXXX(){
    return strXXX;
    class XMLErrorHandler extends DefaultHandler {
    String tagName = "";
    String tagValue = "";
    String applicationRefNo = "";
    String XXXValue ="";
    String XXXNo = "";          
    XMLValidator objXmlValidator = new XMLValidator();
    public void startElement(String uri, String name, String qName, Attributes atts) {
    tagName = qName;
    public void characters(char ch[], int start, int length) {
    if ("Reference".equals(tagName)) {
    tagValue = new String(ch, start, length).trim();
    if (tagValue.length() > 0) {
    RefNo = new String(ch, start, length);
    if ("XXX".equals(tagName)) {
    XXXValue = new String(ch, start, length).trim();
    if (XXXValue.length() > 0) {
    XXXNo = new String(ch, start, length);
    public void endElement(String uri, String localName, String qName) throws SAXException {                    
    if(qName.equalsIgnoreCase("XXX")) {     
    objXmlValidator.setXXX(XXXNo);
    thnx & Regards,
    ritu

  • How to remove Unicode from XML file

    I get following error when unmarshal xml:
    [java] org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x15) was found in the element content of the document.
    Anyone know how to remove Unicode from xml file? Can I remove the unicode by rebuild the file?
    Thanks

    These sort of error usually occur when you're using a different character encoding to read the file than the one you wrote it with. Perhaps if you were to post the problem section of the file and/or the code that created it in the first place.

  • How to extract data from XML file with JavaScript

    HI All
    I am new to this group.
    Can anybody help me regarding XML.
    I want to know How to extract data from XML file with JavaScript.
    And also how to use API for XML
    regards
    Nagaraju

    This is a Java forum.
    JavaScript is something entirely different than Java, even though the names are similar.
    Try another website with forums about JavaScript.
    For example here: http://www.webdeveloper.com/forum/forumdisplay.php?s=&forumid=3

  • How to get Text from (.txt) file to display in the JTextArea ?

    How to get Text from (.txt) file to display in the JTextArea ?
    is there any code please tell me i am begginer and trying to get data from a text file to display in the JTextArea /... please help...

    public static void readText() {
      try {
        File testFile = new File(WorkingDirectory + "ctrlFile.txt");
        if (testFile.exists()){
          BufferedReader br = new BufferedReader(new FileReader("ctrlFile.txt"));
          String s = br.readLine();
          while (s != null)  {
            System.out.println(s);
            s = br.readLine();
          br.close();
      catch (IOException ex){ex.printStackTrace();}
    }rykk

  • How to retrieve image from XML  file

    Hi All,
    I am new to XML. So any best guidance is appreciated.
    The application requirement is to display image retrived from uploaded xml file in file upload section of our application. And store that image in database.
    In my XML file , images & strings & numbers & booleans are there . I am able to save everything in database except images .
    I am using JSF, Seam & Hibernate combination. In my Hibernate entity class i took BLOB datatype for image.
    I am using following tags in my Xhtml file to display image
    <s:graphicImage value="#{hibernateentitybean.picBlobtype}" height="200" width="200">
    <s:transformImageSize width="200" height="200" />
    <s:transformImageType contentType="image/jpeg"/>
    But image is not displayed in Xhtml file
    I am using org.w3c.dom.Document for retrieving node name & corresponding value in that node in XML file.
    I am getting code like below for Image when i am logging all values from XML files in my bean class .
    x0lGQRQAAAABAAAAAAAAAFJHAQARAAAAVwBhAHQAZQByACAAbABpAGwAaQBlAHMALgBqAHAAZwAAAP/Y/+AAEEpGSUYAAQIBAGAAYAAA/+0YLl
    I want to convert this value to image. So i can convert image to bytes and store in BLOB.
    Can anyone guide me ? or any other approach .
    Thanks in advance for any reply.
    Regards,
    Naresh

    Dan_Koldyr wrote:
    agree, it's really odd. Just reread OP and it says:
    NareshDharmiVatsal  wrote:
    want to convert this value to image. In any case it doesn't get worth then another single code line:
    final String cdata = "x0lGQRQAAAABAAAAAAAAAFJHAQARAAAAVwBhAHQAZQByACAAbABpAGwAaQBlAHMALgBqAHAAZwAAAP/Y/+AAEEpGSUYAAQIBAGAAYAAA/+0YLl";
    final sun.misc.BASE64Decoder decoder = new sun.misc.BASE64Decoder();
    final byte[] data = decoder.decodeBuffer(cdata);
    Blob blob = new SerialBlob(data);//or what ever other DB-specific blob implementaiton Did i answered original question? Any more comments to my first replay?I can comment on this latest code. The package sun.misc is private to Sun (Oracle now of course). It is undocumented and may change or be removed altogether in a future release. There is a good free open source Base64 decoder in the Jakarta Commons Codec library.

  • How to get data from a file?

    Hello everyone, i'm new to this forum and to java too. Ok, so here is what i want to do:
    I want to get data from a file containing words and numbers and store them into variables that i will use them after to insert into a database table. For example i have a file called employees.txt in this form:
    eid ename zipcode Hire_date
    1000 "Jones" 67226 "12-DEC-95"
    In C++ i declare variables for each data and store them, for example in this case:
    ifstream in("somefile");
    string name, hdate;
    int eid, zip;
    in >> eid >> ename >> zip >> hdate;
    So i want to do the same thing in JAVA but i can't make it work. So, i would appreciate if someone could give me a simple example how to do it. Thank you.

    [http://java.sun.com/docs/books/tutorial/essential/io/index.html]

  • How to parse contents from XML file in Java

    Hi All,
    I have a scenario like this . I have one xml file with key value pairs of ( name , URL ) . I have retrieved contents from XML file , now I want to parse these contents and store in a bean object.
    How to parse Contents of XML file??
    Thanks in advance,
    Rajendra.

    Hi All,
    I have a scenario like this . I have one xml file with key value pairs of ( name , URL ) . I have retrieved contents from XML file , now I want to parse these contents and store in a bean object.
    How to parse Contents of XML file??
    Thanks in advance,
    Rajendra.

  • 1.6 Dynamic Photo Gallery - alt and title attributes from xml file?

    Hi!
    I would like to attach information to my gallery images from
    the XML-file used by the gallery.
    Especially the alt and title attributes for the "img
    id="mainImage"-tag would add a bit more user friendliness.
    I found
    this
    example about adding caption to images very help full and
    everything worked just fine, thanks to clear information!
    (http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?forumid=72&catid=602&threadi d=1306782&enterthread=y)
    Could someone come up with an example of adding title/alt
    attributes values from XML file?
    I'm sure there are quite a few out ther who would like to see
    a solution to this ;)

    You need to add your info to the XML.
    So something like:
    <photo
    path = "travel_01.jpg"
    width = "263"
    height = "350"
    title="my title"
    alt_text="Alt Text"
    thumbpath = "travel_01.jpg"
    thumbwidth = "56"
    thumbheight = "75">
    </photo>
    Then in your detailregion:
    <img src="{dsData::large/@base}{@path}" alt="{@alt_text}
    title="{@title}" />
    I am using
    http://www.adobe.com/devnet/dreamweaver/articles/spry_photo_album.html
    as the source of my samples...
    So, just add the data to the XML and then you will have these
    attributes available as data references.
    Hope this helps.
    Don

  • How to show records from xml file

    HI All
    I have created one region its actually search region
    which having 5 items and result table region
    I want to search records based on that 5 items and want to show output in table
    I have table name as hr_api_transactions which contains lot of columns
    and that table also contain one column
    name as TRANSACTION_DOCUMENT of type CLOB()
    that columns xml files for each record
    I want to extract data from that xml file and want to display.

    I have created one region on seeded page
    in that region I have created one table for output
    that region is search region
    which having 5 items of textfield and 2 items of type submit button
    GO and Clear
    I want to search based on that 5 items
    I want to display records in table that I have created on that region
    I have one seeded table
    that contain one column
    that column contain xml file for each individual records
    that xaml file contains values what I want to display
    MY problems are
    how can I extract data from xml file?
    how can I show all values for each records on that table?
    how can I search based on that 5 items?
    now I am able to find out single value from that XML file
    by using SQL command
    select xmltype(transaction_document).extract('//IrcPostingContentsVlEORow/CreationDate/text()').getStringVal() CreationDate
    from hr_api_transactions
    where transaction_ref_table = 'PER_ALL_VACANCIES'
    and transaction_ref_id = 4693;how can I extract more than one records from that XML file

  • How can i extract attributes from XML-file

    Hi!
    I want to extract XML-files.
    And the most tags are no problem,but how can i extract attributes?
    Here is a part from the XML-Schema:
    <xs:complexType name="ATT_LIST">
              <xs:sequence>
                   <xs:element name="ATTRIB" minOccurs="0" maxOccurs="unbounded">
                        <xs:complexType>
                             <xs:sequence>
                                  <xs:element name="VALUE"/>
                             </xs:sequence>
                             <xs:attribute name="ATTNAM" use="required"/>
                        </xs:complexType>
                   </xs:element>
              </xs:sequence>
         </xs:complexType>
    Thanks for help.
    With best regards.
    Nicole

    Hi!
    If i delete one '/' i get the error message:
    data can't be found'
    This is my xml-file:
    <?xml version="1.0" encoding="UTF-8"?>
    <INSOBJ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://sv6:8080/sys/schemas/SCOTT/sv6:8080/public/mydocs/inspection_pda_schema.xsd">
         <INSP_PDA>
              <SYSID>900000438</SYSID>
              <INSPECTOR/>
              <INSDAT>20001223</INSDAT>
              <INSOBJ_TYP>MSP-Mast</INSOBJ_TYP>
              <INSOBJ_ID1>BAM / Bad Aussee / Bad Mitterndorf/Grundlsee</INSOBJ_ID1>
              <INSOBJ_ID2>MITTERNDORF 2 - M 259</INSOBJ_ID2>
              <INSOBJ_ID3>239</INSOBJ_ID3>
              <INSOBJ_NAME>259</INSOBJ_NAME>
              <PDA_PORTION>0000000391</PDA_PORTION>
              <GESQUALITAET/>
              <AUSFALLSEINSCH/>
              <ANMERKUNGEN/>
              <LAGE_NORD>48,2281993</LAGE_NORD>
              <LAGE_OST>14,2394658</LAGE_OST>
              <HOEHE/>
              <GPS_STATUS/>
              <KOORD_SYSTEM/>
              <KOORD_EINHEIT/>
              <PLZ/>
              <ORT/>
              <STR_ORTSTEIL/>
              <NUMMER/>
              <BEZEICHNUNG/>
              <GRUNDBESITZER/>
              <TELENR/>
              <ERREICHBARKEIT/>
              <ATT_LIST>
                   <ATTRIB ATTNAM="BAUWEISE">
                        <VALUE>E-Mast</VALUE>
                   </ATTRIB>
                   <ATTRIB ATTNAM="HOLZART">
                        <VALUE>KIEFER</VALUE>
                   </ATTRIB>
              </ATT_LIST>
              <MZ_LIST>
                   <MAS_ZU MZ_NAM="AUSHOLZEN">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM>N</DONE_AM>
                        <DONE_VOM/>
                        <URSACHE>2</URSACHE>
                        <DRINGLICH>2</DRINGLICH>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="ALLGEMEIN-ANMERKUNG">
                        <VALUE>2 Isolatoren</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE>2</URSACHE>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="Stange erdfaul/hohl">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE/>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="Masttyp nicht normgerecht">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE/>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
              </MZ_LIST>
         </INSP_PDA>
         <INSP_PDA>
              <SYSID>900000437</SYSID>
              <INSPECTOR/>
              <INSDAT>20001223</INSDAT>
              <INSOBJ_TYP>MSP-Mast</INSOBJ_TYP>
              <INSOBJ_ID1>BAM / Bad Aussee / Bad Mitterndorf/Grundlsee</INSOBJ_ID1>
              <INSOBJ_ID2>MITTERNDORF 2 - M 259</INSOBJ_ID2>
              <INSOBJ_ID3>239</INSOBJ_ID3>
              <INSOBJ_NAME>259</INSOBJ_NAME>
              <PDA_PORTION>0000000391</PDA_PORTION>
              <GESQUALITAET/>
              <AUSFALLSEINSCH/>
              <ANMERKUNGEN/>
              <LAGE_NORD>48,2281993</LAGE_NORD>
              <LAGE_OST>14,2394658</LAGE_OST>
              <HOEHE/>
              <GPS_STATUS/>
              <KOORD_SYSTEM/>
              <KOORD_EINHEIT/>
              <PLZ/>
              <ORT/>
              <STR_ORTSTEIL/>
              <NUMMER/>
              <BEZEICHNUNG/>
              <GRUNDBESITZER/>
              <TELENR/>
              <ERREICHBARKEIT/>
              <ATT_LIST>
                   <ATTRIB ATTNAM="BAUWEISE">
                        <VALUE>E-Mast</VALUE>
                   </ATTRIB>
                   <ATTRIB ATTNAM="HOLZART">
                        <VALUE>KIEFER</VALUE>
                   </ATTRIB>
              </ATT_LIST>
              <MZ_LIST>
                   <MAS_ZU MZ_NAM="AUSHOLZEN">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM>N</DONE_AM>
                        <DONE_VOM/>
                        <URSACHE>2</URSACHE>
                        <DRINGLICH>2</DRINGLICH>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="ALLGEMEIN-ANMERKUNG">
                        <VALUE>2 Isolatoren</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE>2</URSACHE>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="Stange erdfaul/hohl">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE/>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
                   <MAS_ZU MZ_NAM="Masttyp nicht normgerecht">
                        <VALUE>J</VALUE>
                        <BEMERKUNG/>
                        <INSP_AM/>
                        <INSP_VON/>
                        <DONE_AM/>
                        <DONE_VOM/>
                        <URSACHE/>
                        <DRINGLICH/>
                        <ZIEL_DAT/>
                        <MZ_PARAM_LIST/>
                   </MAS_ZU>
              </MZ_LIST>
         </INSP_PDA>
    </INSOBJ>
    Thanks for help.
    With best regards
    Nicole

  • How to make xsd from xml file?

    Hi,
    i have one xml file which has many node and element.
    anyone know how to make xsd from the xml file in order to make DT by using xsd ?
    Thanks and Best Regards;
    BangBang

    HI
    there are multiple ways of doing this if you have XML based 3rd party tool with you.. you can search on Google also and will get many tools which can convert this to XSD..
    few links with similar discussion..
    How to convert XML file into DTD or XSD
    XML to XSD
    How to creste a XSD ?
    Thanks,
    Bhupesh

  • Create Checkbox with Attributes from XML file

    Hi
    I have some problem. I want to create some checkbox with attribute from a XML file
    my Xml file look like this:
    <group type="Content Relation" color="255, 255, 255" active="true">
    so I want to create for example a check box with name as Content Relation, Background color is RGB(255, 255, 255) and it's checked. All of these Attribute I have readed and save them as String. My question, how can I create a Color object with the color Attribute from the XML file?
    Is it better if I define my XML file like this:
    <group>
    <type>Content Relation</type>
    <color>
    <red>255</red>
    <green>255</green>
    <blue>255</blue>
    </color>
    <active>true</active>
    </group>

    IMO attributes are much easier to parse then textnodes
    altho
    <color red='255' green='255' blue='255'/>
    might be easier

  • How to retrieve data from xml file into obiee reports

    Hi all,
    I've got a situation here. A xml file is stored as blob in oracle database table. Now i need to retrieve data/info from that xml file into obiee reports. How am i supposed to proceed with this ?

    I will go for a table function:
    http://gerardnico.com/wiki/database/oracle/table_function
    In two words, you can create a function that behave as a table. Then you create a function to pick up your xml, you parse it and you send back the rows.
    I know that Oracle has also a library for XML files but I never use it until now.
    Success
    Nico

Maybe you are looking for

  • Serial number error while upgrading to Photoshop CS6

    I just bought from Adobe an upgrade from PS CS3 Extended to PS CS6 Extended, which was indicated as a valid upgrade. Unfortunately, when I enter my 24 digit serial number, get a message saying I have an invalid product for upgrade. I'd like to resolv

  • Distribute update and delete privately

    Is it possible using DPS to have an app distributed privately or not through the app store but the application can still be updated automatically wirelessly? Is there a way to remotely delete an app in case a device is lost or stolen? We are creating

  • How to make a screensaver from my own image?

    How do I size an image to use it as a screensaver?

  • Need to fetch connection, query details

    Hi, How can I get the following details from the system tables: 1) The maximum number of connections that have been in use simultaneously since the server started. 2) Number of times Select, Insert statement has been executed. 3) Number of temp table

  • No video in scrub window after upgrade to imovie '11

    I upgraded from ilife '08 to '11 and after the upgrade I never see any video in the preview window. I don't see it when I scrub/skim clips or when I hit play. When I try to export to a file I also don't see anything in the exported file (black screen