| Author |
Message |
Mark C. Stock *nix forums Guru
Joined: 05 May 2005
Posts: 730
|
Posted: Sun Apr 10, 2005 10:21 am Post subject:
Re: Tree menu with pl/sql and html
|
|
|
"Simo" <yuppie@interfree.it> wrote in message
news:f482699.0504100352.6eee711b@posting.google.com...
| Quote: | "Mark C. Stock" <mcstockX@Xenquery .com> wrote in message
news:<q62dnXux_JiyJMrfRVn-3Q@comcast.com>...
"Simo" <yuppie@interfree.it> wrote in message
news:f482699.0504082316.1b7f99ce@posting.google.com...
Hi!
Does anybody have implemented an html tree with hierarchy query in
pl/sql
language?
I have the right query but i can't show it on html...
Thanks a lot,
Simona
pl/sql web toolkit or HTMLDB?
this probably boils down to a DHTML question...
++ mcs
Pl/sql web toolkit i mean....
bye
simona
|
what type of functionality in the browser are you looking for? do you need
the hierarchy to be dynamic in any way (links, expand/collapse)? how
familiar are you with DHTML?
basically, you're going to loop though your records and issue the
appropriate DHTML tags via htp.p... here's an easy way:
create or replace procedure tree_query
as
begin
htp.p('<p>Tree Query Sample</p>');
-- start HTML table
--
htp.p('<table>');
-- loop thru hierarchical query
--
for r1 in (
select level, ename, job, empno
from emp
connect by prior empno = mgr
start with mgr is null
)
loop
-- start HTML table row
--
htp.p('<tr>');
-- generate empty cells for indent
--
for i in 2..r1.level
loop
htp.p('<td width=15> </td>');
end loop;
-- output row data in the final cell; use colspan so data cell is
not aligned with indent cells
--
htp.p('<td colspan=100>' || r1.ename || ' (' || r1.empno || ') ' ||
r1.job || '</td>');
-- end HTML row
--
htp.p('</tr>');
end loop;
-- end HTML table
--
htp.p('</table>');
end tree_query;
++ mcs |
|
| Back to top |
|
 |
Simo *nix forums beginner
Joined: 18 Mar 2005
Posts: 4
|
Posted: Sun Apr 10, 2005 9:52 am Post subject:
Re: Tree menu with pl/sql and html
|
|
|
"Mark C. Stock" <mcstockX@Xenquery .com> wrote in message news:<q62dnXux_JiyJMrfRVn-3Q@comcast.com>...
| Quote: | "Simo" <yuppie@interfree.it> wrote in message
news:f482699.0504082316.1b7f99ce@posting.google.com...
Hi!
Does anybody have implemented an html tree with hierarchy query in pl/sql
language?
I have the right query but i can't show it on html...
Thanks a lot,
Simona
pl/sql web toolkit or HTMLDB?
this probably boils down to a DHTML question...
++ mcs
|
Pl/sql web toolkit i mean....
bye
simona |
|
| Back to top |
|
 |
Mark C. Stock *nix forums Guru
Joined: 05 May 2005
Posts: 730
|
Posted: Sat Apr 09, 2005 9:14 am Post subject:
Re: Tree menu with pl/sql and html
|
|
|
"Simo" <yuppie@interfree.it> wrote in message
news:f482699.0504082316.1b7f99ce@posting.google.com...
| Quote: | Hi!
Does anybody have implemented an html tree with hierarchy query in pl/sql
language?
I have the right query but i can't show it on html...
Thanks a lot,
Simona
|
pl/sql web toolkit or HTMLDB?
this probably boils down to a DHTML question...
++ mcs |
|
| Back to top |
|
 |
Simo *nix forums beginner
Joined: 18 Mar 2005
Posts: 4
|
Posted: Sat Apr 09, 2005 5:16 am Post subject:
Tree menu with pl/sql and html
|
|
|
Hi!
Does anybody have implemented an html tree with hierarchy query in pl/sql language?
I have the right query but i can't show it on html...
Thanks a lot,
Simona |
|
| Back to top |
|
 |
Google
|
|
| Back to top |
|
 |
|