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

Discrepency in output

Former Member
0 Likes
743

Hi All ,

I have a query , in the below code

wa_exceplist_inv-ADC_VARIANCE = wa_exceplist_inv-AVERAGE_DAILY_CONSUMPTION -

wa_exceplist_inv-PREVIOUS_ADC.

the values for the fields are

wa_exceplist_inv-AVERAGE_DAILY_CONSUMPTION = 25.50

wa_exceplist_inv-PREVIOUS_ADC = 0.00

but the output in the field wa_exceplist_inv-ADC_VARIANCE is 0.00 where in it should be 25.50 ,

the date declaration for the above fields are :

AVERAGE_DAILY_CONSUMPTION type erdz-I_ABRMENGE,

PREVIOUS_CONSUMPTION TYPE erdz-I_ABRMENGE,

PREVIOUS_ADC type erdz-I_ABRMENGE,

ADC_VARIANCE type erdz-I_ABRMENGE,

where erdz-I_ABRMENGE is of the type DEC .

can anyone please give some suggestions on this .

1 ACCEPTED SOLUTION
Read only

keerthy_k
Product and Topic Expert
Product and Topic Expert
0 Likes
693

Hi,

I tried this in my report pgm as below and it is working fine..

data: AVERAGE_DAILY_CONSUMPTION type BBPMENGE value '25.50',

PREVIOUS_CONSUMPTION TYPE BBPMENGE,

PREVIOUS_ADC type BBPMENGE value '0.00',

ADC_VARIANCE type BBPMENGE.

ADC_VARIANCE = AVERAGE_DAILY_CONSUMPTION - PREVIOUS_ADC.

write:/ ADC_VARIANCE.

I am getting 25.50 as output.

Keerthi.

Hi,

I tried this in my report pgm as below and it is working fine..

data: AVERAGE_DAILY_CONSUMPTION type BBPMENGE value '25.50',

PREVIOUS_CONSUMPTION TYPE BBPMENGE,

PREVIOUS_ADC type BBPMENGE value '0.00',

ADC_VARIANCE type BBPMENGE.

ADC_VARIANCE = AVERAGE_DAILY_CONSUMPTION - PREVIOUS_ADC.

write:/ ADC_VARIANCE.

I am getting 25.50 as output.

Keerthi.

4 REPLIES 4
Read only

Former Member
0 Likes
693

Try using type P

Read only

Former Member
0 Likes
693

Hi Balaji

your code seems to be correct, if you are using ALV output, just check your field catalog, whether you are giving correct labels to the fields are not.

Regards,

Rajnesh

Read only

keerthy_k
Product and Topic Expert
Product and Topic Expert
0 Likes
694

Hi,

I tried this in my report pgm as below and it is working fine..

data: AVERAGE_DAILY_CONSUMPTION type BBPMENGE value '25.50',

PREVIOUS_CONSUMPTION TYPE BBPMENGE,

PREVIOUS_ADC type BBPMENGE value '0.00',

ADC_VARIANCE type BBPMENGE.

ADC_VARIANCE = AVERAGE_DAILY_CONSUMPTION - PREVIOUS_ADC.

write:/ ADC_VARIANCE.

I am getting 25.50 as output.

Keerthi.

Read only

Former Member
0 Likes
693

Solved

Edited by: Balaji Krishnamoorthy on Oct 7, 2009 4:32 PM