Solved

Optimizing DB n displaying

Posted on 2006-06-17
2
205 Views
Last Modified: 2010-04-01
hi experts,

I'hv 2 tables 'Menu' &'Sun-Menu' how can I use single stmt or one query to run both n display rs.

Menu Fields :
M-ID      MenuName
Sub-Menu Fields:
S-ID     M-ID      Sub-MenuName

I want o/t 2b:

ABC
   abc-1
   abc-2
XYZ
   xyz-1
   xyz-2
...

Thx
PH

0
Comment
Question by:princehyderabad
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 4

Accepted Solution

by:
pablomorales earned 125 total points
ID: 16934863
You could use the following query to generate your menu

Select m.M-ID,m.MenuName,s.S-ID, s.Sub-MenuName from Menu m, Sub-Menu s where m.M-ID = s.M-ID order by m.M-ID, s.S-ID

You would also need an if statement to detect when the M-ID changes.


0
 

Author Comment

by:princehyderabad
ID: 16936257
Can anyone post the JSP code as well to check for M-ID changes....
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
netstat -a in AIX unix 8 52
servlet concurrency 13 118
difference between projection and projection list in hibernate 1 124
login form jsp example 2 50
Original post  on Monitis Blog. Web performance monitoring is broken into two camps: passive and active. Passive monitoring is defined as looking at real-world historical performance by monitoring actual log-ins, site hits, clicks, requests for…
Always backup Domain, SYSVOL etc.using processes according to Microsoft Best Practices. This is meant as a disaster recovery process for small environments that did not implement backup processes and did not run a secondary domain controller that ne…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question