[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Is this Impossible !!

  • From: Vane Lashua <vlashua@R...>
  • To: xml dev mailing list <xml-dev@i...>
  • Date: Fri, 22 Oct 1999 12:00:42 -0400

RE: Is this Impossible !!
But also see the messages about Oracle's building of XML from the data set returned from an SQL query...
I tried the Oracle's SQL - XML utility and it does what i want.  Except a few things.
I generated the following XML file as a result to a query to my oracle database.
 <ROW num="1">
  <SPNAME>Huntington services Company             </SPNAME>
  <CUSTPERMID>123456789123456     </CUSTPERMID>
  <CUSTLOGINID>jamesb              </CUSTLOGINID>
The ROWSET and the ROW tags were introduced by the builder itself. I would like the document to look like :
<SPNAME>My Own Business  Services Company  </SPNAME>
  <CUSTPERMID>123456789123456     </CUSTPERMID>
  <CUSTLOGINID>jamesb              </CUSTLOGINID>
  <FIRSTNAME>james               </FIRSTNAME>
  <LASTNAME>Bond                </LASTNAME>
This is very important because this xml file will be sent to the client who will "validate" it. Since ROWSET and ROW are not a part of standard message format we use... an exception will be thrown.
Is there any way to customize the output from the builder so that it conforms to a predefined DTD ?
-----Original Message-----
From: Goyal, Sanjeev [mailto:Sanjeev.Goyal@u...]
Sent: Thursday, October 21, 1999 9:49 AM
To: 'Abhishek Srivastava'
Cc: xml dev mailing list
Subject: RE: Is this Impossible !!

Most of the XML Parser implementations provides mechanism to generate well formed XML documents from the DOM Tree. I have used sun's XML parser, it provides APIs to generate well-formed XML from your Document Node.
Hope it helps.
 -----Original Message-----
From: Abhishek Srivastava [mailto:abisheks@i...]
Sent: Wednesday, October 20, 1999 1:29 AM
To: xml dev mailing list
Subject: Is this Immpossible !!

Hi All,
I have the following requirement. A client wants to query a database. It sends out an SQL Query to the Database server. At the server side, instead of returning a recordset, it returns an XML File.
The client on receiving the XML file, parsers it for "Validity" (to be sure that all elements it had asked for are there).
Problem is that at the server side, How to build the xml document.
Presently, I am doing something like this
String("<Name>") + rs.getField("auName") + String("</Name>")
However, this is a very inelegant approach as the code is full of such string concatenations.
Is there a more elegant solution to this ?  All the material on XML talks about parsing and reading XML. What about writing them ? Are there DOM / SAX Api extensions available that would
create "VALID" XML documents without clutter in the code ?
Any help would be greatly appreciated.
Thanks & Best Regards,
    _/               Abhishek Srivastava
   _/                Hewlett Packard ISO      
  _/_/_/   _/_/_/    -------------------  
 _/   /   _/  _/     (Work)   +91-80-2251554 x1190
_/  _/   _/_/_/      (Ip)           
        _/           (Url)    http://sites.netscape.net/abhishes/homepage                       
       _/            You've heard it all by now. Get wired or get whacked.
                     You're networking or you're not working. Dot-com or die
                     - SUN MICROSYSTEMS 


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.

Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.