2006 Apr 07 10:05 PM
From table BSEG I have to pick up the amounts for hkont = 22500000000 for all the BELNR present in BKPF and insert the values in another z-table z_ven_inv. This HKONT has posting for 40 as well as 50... that means all the amounts of 40 have to be added & then all the amounts with 50 needs to be subtracted to balance the amount againt that HKONT (GL account).
My issue is the the table z_ven_inv shows all the rows for HKONT 2250000000 for that document. It does not have the field BSCHL. How can I show a -ve value in table z_ven_inv ??
Below is the example of a document from FB03:-
31 89000 2,288.00-
31 89000 1,519.00-
31 89000 1,494.50-
31 89000 1,797.60-
Total :- 7,099.10-
40 2250000000 2,288.00
40 2250000000 1,562.40
50 2250000000 43.40-
40 2250000000 1,494.50
40 2250000000 1,797.60
Total :- 7,099.10
The z_ven_inv table shows the values
2,288.00
1,562.40
43.40
1,494.50
1,797.60
How do I show that 43.40 is a -ve amount ??
Thank You,
SB.
2006 Apr 07 10:36 PM
Can you not change the table to include either BSCHL or SHKZG which will tell you whether the amount is positive or negative?
2006 Apr 07 10:26 PM
Change the domain for the amount field in the Z table to allow negative values.
rob
2006 Apr 07 10:36 PM
Can you not change the table to include either BSCHL or SHKZG which will tell you whether the amount is positive or negative?
2006 Apr 08 1:09 AM
Hi SB,
To add onto Rob' suggestion..
In SE11 display your Z Table> Double click on the data element against the Amount field> Double click on the Domain-->In the Outout Characteristics block, click the Sign checkbox & activate the Domain.
Regards,
Suresh Datti
2006 Apr 08 1:13 AM
Hi Srinivas,
This table is then used by some other team to produce output reports for the end users... so only I am not sure if BSCHL is required by their team .... Can you suggest something else ?? I want to try all possibilities at my side before asking the other team to change ...
Thank You,
SB.
2006 Apr 08 5:29 AM
Hi Suresh,
Thanks for the ellaborate explanation I did the change in my z-table but in the program I am writing z_ven_inv-wrbtr = t_bseg-wrbtr... How do I code to say that change the amount in z_ven_inv to -ve sign where t_bseg-bschl = 50 ??
Thanks a lot for your help.
SB.
2006 Apr 08 8:10 AM
2006 Apr 08 8:13 AM
<i>How do I code to say that change the amount in z_ven_inv to -ve sign where t_bseg-bschl = 50 ??</i>
multiply by -1
Raja
2006 Apr 09 3:57 AM
BSEG-BSCHL can have a lot more values than '40' or '50'. I would look at the debit credit indicator. So:
IF t_bseg-SHKZG = 'H'.
z_ven_inv-wrbtr = t_bseg-wrbtr * -1.
ELSE.
z_ven_inv-wrbtr = t_bseg-wrbtr.
ENDIF.
(You may want to display the amounts with the opposite sense.)
Rob
2006 Apr 09 6:03 AM
Hi,
I am not getting the radiobutton display where I can award the answers that helped me solve my problem... Please tell me what should I do ??
Thank You,
SB.
2006 Apr 09 6:13 AM
looks like the points system is down. check back later to reward points and close the thread.
Regards
Raja