Re: Generate multi-level XML document using standard SQL select statement

2002-05-13 Thread Christian Haul

On 13.May.2002 -- 01:44 AM, Evan Sho wrote:
> Well, just prepared a Generator which take a SQL
> statment as src, and generate multi-level XML
> document.
> 
> Please kindly give me some comments? 
> http://www.evansho.net/SqlGenerator.zip

Looks nice. Evan, do you like to donate that code (and some docs about
it ;-) ?

> BTW, how should I do pagination in cocoon? I mean if I
> have 100+ rows and want to display them page by page
> with 10 rows per page, is there any general practice
> to do that?

a) esql supports skip rows and max rows
b) there's a paginating transformer in scratchpad
c) FilterTransformer does paginating

Chris.

-- 
C h r i s t i a n   H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




Re: Generate multi-level XML document using standard SQL select statement

2002-05-13 Thread Evan Sho

Well, just prepared a Generator which take a SQL
statment as src, and generate multi-level XML
document.

Please kindly give me some comments? 
http://www.evansho.net/SqlGenerator.zip

BTW, how should I do pagination in cocoon? I mean if I
have 100+ rows and want to display them page by page
with 10 rows per page, is there any general practice
to do that?

Regards
Evan


--- Christian Haul
<[EMAIL PROTECTED]> wrote:
> On 12.May.2002 -- 10:17 AM, Evan Sho wrote:
> > Just tried MS SQL server 2000. I can type in
> browser:
> > http://localhost/mydb?sql=select * from dept, emp
> > where dept.deptno=emp.dept.no for xml
> auto&root=List
> > 
> > then, I will get XML:
> > 
> >   
> > 
> > 
> >   
> >   
> > 
> >   
> >   ...
> > 
> > 
> > The nesting of joined result is automatic, and I
> found
> > that it is very useful. so is there any similar
> tool
> > that can be used to get similar result?
> 
> Have a look at . It's not automatic as
> such but obtaining
> a result like the above would be easy. Alas, the
> query needs to be
> known beforehand.
> 
> An automatic tools would need to have more knowledge
> about database
> metadata and parse the query.
> 
> HTH
> 
>   Chris.
> 
> -- 
> C h r i s t i a n   H a u l
> [EMAIL PROTECTED]
> fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9
> 6856 335A 9E08
> 
> 
>
-
> Please check that your question has not already been
> answered in the
> FAQ before posting.
> 
> 
> To unsubscribe, e-mail:
> <[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <[EMAIL PROTECTED]>
> 


__
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




Re: Generate multi-level XML document using standard SQL select statement

2002-05-13 Thread Christian Haul

On 12.May.2002 -- 10:17 AM, Evan Sho wrote:
> Just tried MS SQL server 2000. I can type in browser:
> http://localhost/mydb?sql=select * from dept, emp
> where dept.deptno=emp.dept.no for xml auto&root=List
> 
> then, I will get XML:
> 
>   
> 
> 
>   
>   
> 
>   
>   ...
> 
> 
> The nesting of joined result is automatic, and I found
> that it is very useful. so is there any similar tool
> that can be used to get similar result?

Have a look at . It's not automatic as such but obtaining
a result like the above would be easy. Alas, the query needs to be
known beforehand.

An automatic tools would need to have more knowledge about database
metadata and parse the query.

HTH

Chris.

-- 
C h r i s t i a n   H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




Generate multi-level XML document using standard SQL select statement

2002-05-12 Thread Evan Sho

Just tried MS SQL server 2000. I can type in browser:
http://localhost/mydb?sql=select * from dept, emp
where dept.deptno=emp.dept.no for xml auto&root=List

then, I will get XML:

  


  
  

  
  ...


The nesting of joined result is automatic, and I found
that it is very useful. so is there any similar tool
that can be used to get similar result?

Thanks
Evan



__
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>