<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2653.12">
<TITLE>RE: [jdom-interest] SQL join -> Structured XML</TITLE>
</HEAD>
<BODY>
<P><FONT SIZE=2>i was excepting more like what is done in Xalan extensions.</FONT>
<BR><FONT SIZE=2>They have a concept of streaming resultset which is being </FONT>
<BR><FONT SIZE=2>treated like a document. so when you loop through the </FONT>
<BR><FONT SIZE=2>document, resultset cursor moves one after the other. this</FONT>
<BR><FONT SIZE=2>helps in streaming (not loading the whole of resultset </FONT>
<BR><FONT SIZE=2>and bloating the memory). such utility can be a great JDOM</FONT>
<BR><FONT SIZE=2>extension.</FONT>
</P>
<P><FONT SIZE=2>mani</FONT>
</P>
<BR>
<P><FONT SIZE=2>-----Original Message-----</FONT>
<BR><FONT SIZE=2>From: Philippe Lang [<A HREF="mailto:philippe.lang@attiksystem.ch">mailto:philippe.lang@attiksystem.ch</A>]</FONT>
<BR><FONT SIZE=2>Sent: Friday, April 26, 2002 11:30 AM</FONT>
<BR><FONT SIZE=2>To: jdom-interest@jdom.org</FONT>
<BR><FONT SIZE=2>Subject: RE: [jdom-interest] SQL join -> Structured XML</FONT>
</P>
<BR>
<P><FONT SIZE=2>These classes are useful for reporting, not exactly for search. We send</FONT>
<BR><FONT SIZE=2>a query with joins to the database, get back a tabular result</FONT>
<BR><FONT SIZE=2>(CachedRowSet), create a structured XML file from this result, and sent</FONT>
<BR><FONT SIZE=2>it to FOP, which can ouput PDF, PCL, PS... The classes do not generate</FONT>
<BR><FONT SIZE=2>code.</FONT>
</P>
<P><FONT SIZE=2>Is there another way to get XML from a database query with joins? I know</FONT>
<BR><FONT SIZE=2>some databases can actually give back XML directly, instead of a tabular</FONT>
<BR><FONT SIZE=2>result, but this is not a feature we can rely on. It's not portable</FONT>
<BR><FONT SIZE=2>enough.</FONT>
</P>
<P><FONT SIZE=2>Philippe</FONT>
</P>
<P><FONT SIZE=2>-----Message d'origine-----</FONT>
<BR><FONT SIZE=2>De : Mani Doraisamy [<A HREF="mailto:MDoraisamy@SELECTICA.com">mailto:MDoraisamy@SELECTICA.com</A>]</FONT>
<BR><FONT SIZE=2>Envoyé : jeudi, 25. avril 2002 17:03</FONT>
<BR><FONT SIZE=2>À : Nott, Matthias; Philippe Lang; jdom-interest@jdom.org</FONT>
<BR><FONT SIZE=2>Objet : RE: [jdom-interest] SQL join -> Structured XML</FONT>
</P>
<BR>
<P><FONT SIZE=2>Transforming XML to db might follow the standard </FONT>
<BR><FONT SIZE=2>object model to ER conversion. so by establishing </FONT>
<BR><FONT SIZE=2>a schema which has one to one relationship with </FONT>
<BR><FONT SIZE=2>ER tables, we might able to convert from db to </FONT>
<BR><FONT SIZE=2>xml and from xml to db back. What Phillippe has done </FONT>
<BR><FONT SIZE=2>might be useful in search. it would be great if he </FONT>
<BR><FONT SIZE=2>can share the code. </FONT>
<BR><FONT SIZE=2>mani </FONT>
</P>
<P><FONT SIZE=2>-----Original Message----- </FONT>
<BR><FONT SIZE=2>From: Nott, Matthias [<A HREF="mailto:mnott@vignette.com">mailto:mnott@vignette.com</A>] </FONT>
<BR><FONT SIZE=2>Sent: Thursday, April 25, 2002 3:57 PM </FONT>
<BR><FONT SIZE=2>To: Philippe Lang; jdom-interest@jdom.org </FONT>
<BR><FONT SIZE=2>Subject: RE: [jdom-interest] SQL join -> Structured XML </FONT>
</P>
<BR>
<P><FONT SIZE=2>goes sort of the direction of program generators, </FONT>
<BR><FONT SIZE=2>if you want to reimport xml into the db by transforming </FONT>
<BR><FONT SIZE=2>your xml into e.g. stored proc calls. There's quite a lot </FONT>
<BR><FONT SIZE=2>of material around on that. </FONT>
<BR><FONT SIZE=2>M </FONT>
</P>
<P><FONT SIZE=2>-----Original Message----- </FONT>
<BR><FONT SIZE=2>From: Philippe Lang [<A HREF="mailto:philippe.lang@attiksystem.ch">mailto:philippe.lang@attiksystem.ch</A>] </FONT>
<BR><FONT SIZE=2>Sent: Thursday, April 25, 2002 8:18 AM </FONT>
<BR><FONT SIZE=2>To: jdom-interest@jdom.org </FONT>
<BR><FONT SIZE=2>Subject: [jdom-interest] SQL join -> Structured XML </FONT>
</P>
<BR>
<P><FONT SIZE=2>Hi, </FONT>
<BR><FONT SIZE=2>I have written a set of classes that take as input the result of an SQL </FONT>
<BR><FONT SIZE=2>query, with joined tables. Given some parameters you give to the classes</FONT>
</P>
<P><FONT SIZE=2>(groups, sort order...), very similar to what you can configure in </FONT>
<BR><FONT SIZE=2>Access or Crystal Reports, it outputs an XML file, with the same data, </FONT>
<BR><FONT SIZE=2>but in a structured way. It works with any number of joins. </FONT>
<BR><FONT SIZE=2>I wonder if it would be a good idea to incorporate these classes in </FONT>
<BR><FONT SIZE=2>JDOM? Or does that go beyond the scope of JDOM? </FONT>
</P>
<BR>
<P><FONT SIZE=2>Example: </FONT>
<BR><FONT SIZE=2>-------- </FONT>
<BR><FONT SIZE=2>(CachedRowSet) </FONT>
<BR><FONT SIZE=2>A P1 P2 </FONT>
<BR><FONT SIZE=2>A P3 P4 </FONT>
<BR><FONT SIZE=2>A P5 P6 </FONT>
<BR><FONT SIZE=2>B P7 P8 </FONT>
<BR><FONT SIZE=2>B P9 P10 </FONT>
<BR><FONT SIZE=2>A P11 P12 </FONT>
<BR><FONT SIZE=2>C P13 P14 </FONT>
<BR><FONT SIZE=2>gives... </FONT>
</P>
<BR>
<P><FONT SIZE=2>(XML) </FONT>
<BR><FONT SIZE=2>----- A ----- P1 P2 </FONT>
<BR><FONT SIZE=2> | |-- P3 P4 </FONT>
<BR><FONT SIZE=2> | |-- P5 P6 </FONT>
<BR><FONT SIZE=2> | |-- P11 P12 </FONT>
<BR><FONT SIZE=2> | </FONT>
<BR><FONT SIZE=2> |- B ----- P7 P8 </FONT>
<BR><FONT SIZE=2> | |-- P9 P10 </FONT>
<BR><FONT SIZE=2> | </FONT>
<BR><FONT SIZE=2> |- C ----- P13 P14 </FONT>
</P>
<BR>
<BR>
<P><FONT SIZE=2>------------------------- </FONT>
<BR><FONT SIZE=2>Philippe Lang </FONT>
<BR><FONT SIZE=2>Attik System </FONT>
<BR><FONT SIZE=2><A HREF="http://www.attiksystem.ch" TARGET="_blank">http://www.attiksystem.ch</A> </FONT>
<BR><FONT SIZE=2>_______________________________________________</FONT>
<BR><FONT SIZE=2>To control your jdom-interest membership:</FONT>
<BR><FONT SIZE=2><A HREF="http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourhost.com" TARGET="_blank">http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourhost.com</A></FONT>
</P>
</BODY>
</HTML>