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: 

Select

Former Member
0 Kudos

hi to all,

help me in this issue

SELECT *

FROM ZFtable

INTO IT_cus

WHERE ZSTAT = IT_CUSBAL-ZSTAT

AND ZINVIND = ' '

AND TRANSINST EQ ' '

when i keep this transinst eq ' ' it is not collecting any date but date is therein database is there any mistake in select stament.

thanks in advance

kiran kumar

1 ACCEPTED SOLUTION

Former Member
0 Kudos

You can do the following :

SELECT *

FROM ZFtable

INTO IT_cus

WHERE ZSTAT = IT_CUSBAL-ZSTAT

AND ZINVIND = ' '

AND TRANSINST <b>= SPACE.</b>

7 REPLIES 7

Former Member
0 Kudos

You can do the following :

SELECT *

FROM ZFtable

INTO IT_cus

WHERE ZSTAT = IT_CUSBAL-ZSTAT

AND ZINVIND = ' '

AND TRANSINST <b>= SPACE.</b>

0 Kudos

hi ravi,

with keeping sapce also it is not working.

thanks and regards

kiran kumar

Former Member
0 Kudos

Hi,

Check the data type of this field "TRANSINST"...

also check the initial value of the data type..

Try to compare it with the initial value.

Regards

Former Member
0 Kudos

Hi Kiran,

Kindly try this code:

SELECT * FROM zftable INTO it_cus
WHERE zstat EQ it_cusbal-zstat
AND   zinvind <b>IS INITIAL</b>
AND   transinst <b>IS INITIAL</b>.

hope this helps!

best regards,

Thangesh

Former Member
0 Kudos

Hi kiran,

there are 2 ways.

first create a field like TRANSINST and let it initial.

data TRANSINST like ZFTABE-TRANSINST.

*

SELECT * FROM ZFTABE where TRANSINST = TRANSINST.

...

...

ENDSELECT.

*

Another way is to check with initial.

Regards, Dieter

Message was edited by: Dieter Gröhn

Former Member
0 Kudos

It seems that the value in the field for TRANSINST is not SPACE. Hence It is not returning you any data.

former_member404244
Active Contributor
0 Kudos

Hi kiran,

u query is fine..but It seems that the value in the field for TRANSINST is not equal to SPACE. So u r not getting any values.Chek the same...

Regards,

nagaraj