Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

how to get the display based on selection-screen criterio

Former Member
0 Kudos

hi friends,

I have to generate an alv list with PO data,Delivery data,shipment data etc.

i have the following fields in my sel-screen.

1) In block 1

- PO date(EKET-EINDT)

- Shipment start date(VTTK-DPTBG)

- Shipment end date(VTTK-DPTEN)

2) In block 2 (all primary keys)

- MATNR

- WERKS

- LIFNR

- EBELN

- VBELN

- SIGNI(container id)

So, the main logic is they have six sel-screen conditions.

1) if the user selects the PO date in 1st block then they need the data based on PO date and the fields in 2nd block should serve as additional filters and it should display a list.

2) if the user selects the shipment start date in 1st block then they need the data based on shipment number and shipment start date and the fields in 2nd block should serve as additional filters and it should display a list.

3) if the user selects the shipment end date in 1st block then they need the data based on shipment number and shipment end date and the fields in 2nd block should serve as additional filters and it should display a list.

4) if either or multiples of the fileds in 2nd block r selected and the date range in 1st block in blank then they need the display based on the PO item with the respective material.

5) If VBELN is selected in 2ND block and the date range in 1st block is blank then they need the display based on the VBELN only.

6) If SIGNI is selected in 2ND block and the date range in 1st block is blank then they need the display based on the SIGNI and TKNUM in VTTK .

I am getting all the report fields into a final output internal table by using for all entries and reading those tables and then moving them into the final output table.

i am getting the way to write the logic in at selection-screen on the same field whcih ever the user selects .

Can anybody suggest me with the proper and perfect logic for all of the above conditions.

Regards

Mahesh

3 REPLIES 3

Former Member
0 Kudos

Hi,

In your selection screen ,

consider if S_EINDT is PO Date

S_DPTBG is Shipment start date(VTTK-DPTBG)

S_DPTEN is Shipment end date(VTTK-DPTEN)

S_MATNR - MATERIAL NO

S_WERKS - PLANT

S_LIFNR - VENDOR

S_EBELN - PONO

S_VBELN - INVOICE NO , then in your corresponding select query you have to check if the field is equal to the field given in the selection screen input.

Note:Check it in "WHERE" Condition.

Eg:

Select ebeln lifnr from ekko into table itab-ekko where ebeln in s_ebeln and lifnr in s_lifnr.

For all the select queries which has these fields check the where condt.Hope this will be useful for you.

Regards,

P.S.Chitra

0 Kudos

thanks chitra,

i will try with this surely,if i have any issue in this i will get back to u.

Former Member
0 Kudos

thanks a lot