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: 

Displaying Unit of measure field with Quantity field

Former Member
0 Kudos

Hi Experts,

In my AlV List i have to display field 'unit of measure' with the field 'Quantity'.

Both have different datatypes.I am also doing the subtotal on the Quantity field.So if i concatenate the unit of measure field it does'nt works.

Advice me!

Regards,

Simran

9 REPLIES 9

Former Member
0 Kudos

You can only display UOM and qty in separate columns. you cannot concatenate and display them

suresh_datti
Active Contributor
0 Kudos

If the UOM is same for all the entries show it as the coulmn heading for qty field,else, display it in another column..

~Suresh

0 Kudos

Hi,

I can display it as column heading in the quantity column but how to display it with record as well.

e.g. HOURS H

2.00 H

3.50 H

Regards,

Simran

0 Kudos

one way...

u can defind char type field for target field.

and concanate both field into char field and display it.

data: target(22).

1614+1

16-for curr

1-decimal.

4-uom.

1-space

0 Kudos

Hi,

if i define target field as CHAR type,how can i perform the subtotal operation on it.

Regards,

Simran

0 Kudos

ya u can make one more column for target field.

do sub total on privious curr field.

but when u dispaly it in alv hide privious field of curr only display target field.

for hide filed in alv use <b>fieldcat-no_out = 'X'</b>. for that field

0 Kudos

Hi,

I tried using a target field and concatenating unit of measure with currency in it.

However when i am hiding the currency field in fieldcatlog it also inactivates the do_sum logic.

Advice me!

simran

Former Member
0 Kudos

HI Simran,

Uneed to look at the below speps to make use of summing functionality.

Populate the below fileds also in the Fild catelog depending on your requrement.

currency(5) type c,

cfieldname type slis_fieldname, " field with currency unit

ctabname type slis_tabname, " and table

quantity(3) type c,

qfieldname type slis_fieldname, " field with quantity unit

qtabname type slis_tabname, " and table

Message was edited by: Mohammed Jaleel

0 Kudos

Hi,

I tried with your code but its not working.

Can you elaborate a bit on it.

my Quantity field is HOURS

and unit of measure field is MEINH

wht value should i assign to fieldcat-currency & fieldcat-quantity and should i use do_sum field and no_out (for hiding) also alongwith,

Simran