Application Development and Automation 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: 
Read only

range in the selection screen

Former Member
0 Likes
789

Hi,

How can we know the number of values inputed in the selection screen of a select-option(no interval)...

thank you...

regards,

mae

6 REPLIES 6
Read only

naimesh_patel
Active Contributor
0 Likes
756

You can use the <b>describe</b> statment to get that number:

Like:


tables: bkpf.

select-options: s_date for bkpf-budat.


start-of-selection.
 describe table s_date lines sy-index.
 write: sy-index.

Regards,

Naimesh Patel

Read only

0 Likes
756

hi,

ehat if i have a value in my range..a,b,c,d,e,f,a,b and c...

how will i caount it that a,b and c will be count as 1..i mean if there is a same value in the field it will juct be counted as 1..

in the example above..the number of data in the reange will be counted as 6 not 9 because a,b and c are inputed twice so i just ned to caount it as 1.

thank you...

regards,

mae

Read only

0 Likes
756

Why would you have the same value as an INput value in your selection screen twice.

Shreekant

Read only

0 Likes
756

because sometimes the users inputed it twice..

does it affect the number of value in the range?

thank you...

regards,

mae

Read only

0 Likes
756

Ok..

Do like:

REPORT  ZTEST_NP.

TABLES: BKPF.

SELECT-OPTIONS: S_DATE FOR BKPF-BUDAT.

START-OF-SELECTION.
  SORT S_DATE.
  DELETE ADJACENT DUPLICATES FROM S_DATE.
  DESCRIBE TABLE S_DATE LINES SY-INDEX.
  WRITE: SY-INDEX.

Regards,

Naimesh Patel

Read only

Former Member
0 Likes
756

Hi Naimesh Patel,

Thank you, it's a lot of help...

regards,

mae