‎2007 Jan 21 8:18 AM
Hi and good morning,
I've problem in getting the data..... I guess the problem is in my select statement.....please help?
a b c d
w1 h01 h12 12/04/06
w2 wc1 hr8 01/08/04
where a,b and c are of char type and d is of date type... my select statement is
select a b c d from mara into corresponding
fields of table it_tab2 where a = pa_a and c in
s_c and b in s_b.
it is not working please suggest.....
‎2007 Jan 21 6:15 PM
Hi,
Check the following.
1) Make sure you have the records in the table MARA for the corresponding combination give in the selection screen...
2) Also make sure the parameter pa_a is entered in the selection-screen..
Since in the where clause..You are using EQ operator..Which means if the value is not give in the selection screen..It will look for blank value..
Make the parameter as mandatory OR if it is optional parameter..Use SELECT-OPTIONS NO INTERVALS NO-EXTENSION addition..And use IN in your select statement..
Example
-
SELECT-OPTIONS SO_A FOR MARA-A.
select a b c d from mara into corresponding
fields of table it_tab2 where <b>A IN SO_A</b> and c in
s_c and b in s_b.
Thanks,
Naren
‎2007 Jan 21 8:23 AM
can u post exact select statement along with description of internal table.
regds,
kiran
‎2007 Jan 21 8:35 AM
Hi Shaheen,
Just check how the DATE is stored in database.
Usually its as per User setting or YYYYMMDD format.
So you need to change your Select-option Date format in to User setting or YYYYDDMM format and then select.
Reward points if this Helps.
Manish
‎2007 Jan 21 8:36 AM
HI,
The date is stored as YYYYMMDD internally in the Database.
Use some date conversion FM or some other technique to change date fromYYYYMMDD to DD/MM/YY format and then display it on the screen.
Hope this info helps you.
Regards
Subramanian
‎2007 Jan 21 8:40 AM
sorry guys I forgot to add this ..... that my problem is in the char fields b & c..... the rows underneth these to colums I'm getting it as blank no data is dispalyed .... thanks in advance.
‎2007 Jan 21 3:00 PM
Hi,
Are u using the selct query in a loop? In dat case u need to use appending in ur query.
‎2007 Jan 21 6:15 PM
Hi,
Check the following.
1) Make sure you have the records in the table MARA for the corresponding combination give in the selection screen...
2) Also make sure the parameter pa_a is entered in the selection-screen..
Since in the where clause..You are using EQ operator..Which means if the value is not give in the selection screen..It will look for blank value..
Make the parameter as mandatory OR if it is optional parameter..Use SELECT-OPTIONS NO INTERVALS NO-EXTENSION addition..And use IN in your select statement..
Example
-
SELECT-OPTIONS SO_A FOR MARA-A.
select a b c d from mara into corresponding
fields of table it_tab2 where <b>A IN SO_A</b> and c in
s_c and b in s_b.
Thanks,
Naren
‎2007 Jan 22 3:56 AM