‎2005 Sep 27 12:41 PM
Hi,
I want to know how to provide drill down functionality in ABAP query.
I have the doc www.sappoint.com/abap/ab4query.pdf .
In this doc, it is saying that create a query with multiple line basic lists. How to do it?
I have to display the data from one table. so can't create any foreign key relationship.
So can I generate a drill-down report here?
Please advise.
regards,
Beena
‎2005 Sep 27 12:45 PM
hi,
are you design the query with the abap program, if it is so drill down is possible
in the program you add the below logic
at user-command.
l_case = sy-lisel+1(8).
l_matnr = sy-lisel+23(18).
if l_case = 'Material'.
set parameter id 'MAT' field l_matnr.
call transaction 'MMBE' and skip first screen.
endif.
cheers,
sasi
‎2005 Sep 27 12:48 PM
Hi Sasi,
Thanks for the reply.
But I am using the SQ01 transaction (Abap/4 query using external program)
‎2005 Sep 27 12:59 PM
hi,
you are correct. SQ01 only we design the query
In SQ02 we design our infoset in the infoset there is an option like
Table join by basis table
direct read of table
logical database
and
data retrieval by program
if you choose the 4th option we will achieve drill down
in the 4th option we need to speficy the program name and
one structure name
in the abap program we retrive all the values and populate in the structure, the program will pass the strcture to the query
like
*<Query_head>
loop at gt_equp.
on change of gt_equp-matnr.
l_sno = 0.
endon.
l_sno = l_sno + 1.
move-corresponding gt_equp to ysmmr_equipping.
move l_sno to ysmmr_equipping-sno.
ysmmr_equipping-totamount = 0.
if gt_equp-vprsv = 'V'.
ysmmr_equipping-totamount = gt_equp-menge * gt_equp-verpr.
elseif gt_equp-vprsv = 'S'.
ysmmr_equipping-totamount = gt_equp-menge * gt_equp-stprs.
endif.
if gt_equp-vprsv = 'V'.
ysmmr_equipping-stprs = gt_equp-verpr.
endif.
if gt_equp-gernr = 'X'.
ysmmr_equipping-gernr = space.
loop at gt_sernr where mblnr = gt_equp-mblnr and
mjahr = gt_equp-mjahr and
sno = gt_equp-sno.
ysmmr_equipping-gernr = gt_sernr-gernr.
endloop.
endif.
read table gt_name with key bname = gt_equp-wempf.
if sy-subrc = 0.
ysmmr_equipping-title = gt_name-title.
ysmmr_equipping-name_last = gt_name-name_last.
endif.
*<Query_body>
endloop.
ysmmr_equipping is a structure attached in the infoset
cheers,
sasi
‎2005 Sep 27 12:53 PM
Hi,
belwo link may help you.
http://help.sap.com/saphelp_erp2004/helpdata/en/5c/8daff6555411d189660000e829fbbd/frameset.htm
regards,
venu.
‎2005 Sep 27 1:28 PM
But how to do drill down here?
For that we have to create two infosets and multi line basic lists.
How to do it? I haven't seen any option like multi line basic lists in in sq01.
Please help
‎2005 Sep 27 2:05 PM
Hello,
Create 2 lists.
Take the basÃc list go in change mode.
Under edit , select output sequence.
Assign order of the lists as sub lists.
Ensure to have the key field to be there as input parameter on second list.
Rgds,
Manohar E
‎2005 Sep 27 2:10 PM
‎2005 Sep 28 4:35 AM
Hi,
I am explaining my requirement here.
I have an abap query which displays customer no, name , sales and collection. It displays the values and it is working fine.
Now I have to modify this report. When I click on the customer number, it should display the line items.Already I have one structure and one Infoset.
I think I have to create one more structure to display the lineitems. then one more infoset.
But I don't know how to add one more infoset in the same query. I got one reply from Mano that I have to create two basic lists.
How to create one more list in the same query? I tried to create but I couldn't.
Please advise.