on 09-19-2008 1:12 PM
Hi all,
I have the following question :
In my abap program u have the following:
data : WA_count type i.
select single * from nast where kappl = 'EV'.
after this statement is nast-anzal = 1 (type of nast-anzal is
DEC2).
wa_count = nast-anzal.
so far so good.
On my sapscript :
/: if &wa_count& = 1.
One
/: else.
Others
/: endif.
The word 'Others' is printed (i accept One ).
Its seems simple but i dont know what i do wrong.
I tried also with : if &nast=anzal& = 1 ('1' eq ..etc)
Thanks
Thanks gustavo ..
The &wa_count(C)& works perfect ..
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try this, before doing the comparation, print the actual value of wa_count in the sapscript.This way you can check the exact value the sapscript is receiving.
You can also take off the /: and replace it with * in the if line, because perhaps extra spaces there are disrupting the command, and this way you can see it. In that case try using &wa_count(C)& to condense the extra spaces.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
still doenst't working
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Adel,
Can you change your WA_COUNT declaration from type I to NAST-ANZAL type and try again.
DATA WA_COUNT TYPE NAST-ANZAL.
/: if &wa_count& = '1'.
One
/: else.
Others
/: endif.
Thanks,
Vinay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Of course i died he debugging before posting the question.
The value is 1 .
Hexadicam value is 001C.
But it still not working.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Debug your code/script to find out value of nast-anzal.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi..
It could be '01'. Please check the value that is retreived from nast is 1 or 01.
The rest looks fine.
Regards,
Vishwa.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.