I have a requirement, where from front end (JSP)
- If market is selected, sectors mapped to Markets have to populate
- Likewise, based on sector value selected, End Equipment has to populate.
Market --1st Drop down
Sector --2nd Drop down
Webcategory -- 3rd Drop down
So initially for getting this page, there will be a database hit, so as oracle DB developer, I have to send OUT parameter containing this mapping.
End Equipment mapped to Sector and mapped to Market.
I am using below query which is not giving my result as required.
SELECT C.MARKET_SEGMENT_NAME,
C.MARKET_SEGMENT_ID,
B.SECTOR_NAME,
B.SECTOR_ID,
A.WEB_CATEGORY_NAME,
A.WEB_CATEGORY_ID
FROM MSE_WEB_CATEGORY_MASTER A,
MSE_SECTOR_MASTER B,
MSE_MARKET_SEGMENT_MASTER C
WHERE C.MARKET_SEGMENT_ID = B.FK_MARKET_SEGMENT_ID
AND B.SECTOR_ID = A.FK_SECTOR_ID(+);
Output:
MARKET_SEGMENT_NAME MARKET_SEGMENT_ID Sector Sector_id WEB_cate Web_category_id
GOOGLE 90 Slawn 1 FLIPKART 1
BING 100 Clown 2 SNAPDEAL 2
YAHOO 110 VERICON 4 AMAZON 3
YAHOO 110 VERICON 4 E-KART 4
YAHOO 110 QUALCOMM 3
Expected Output:
MARKET_SEGMENT_NAME-MARKET_SEGMENT_ID-SECTOR_NAME-SECTOR_ID-WEB_CATEGORY_NAME-WEB_CATEGORY_ID
GOOGLE-90-Slawn-1-FLIPKART-1
BING-100-Clown-2-SNAPDEAL-2
YAHOO-110-VERICON-4-AMAZON-3
YAHOO-110-VERICON-4-E-KART-4
YAHOO-110-QUALCOMM-3
so that I can send this combination as an Output parameter from my procedure. Since there is a restriction for not to have DB queries in JSP/presentation layer, everything is been done on DB layer.