10-08-2008 12:42 PM
Hi,
I have written the code as
submit rabewg_alv01 with bukrs = p_bukrs
with brdatu = lv_lastdate
with ktansw = p_ktansw
with budat-low = lv_start
with budat-high = lv_end
using selection-set 'DEFECT '
and return.
In the o/p which is getting generated it is not taking into account the value of bukrs,brdatu,ktansw and budat.The o/p which is getting displayed is only based on the variant set.How to rectify this error
10-08-2008 1:06 PM
submit rabewg_alv01 using selection-set 'DEFECT '
with bukrs = p_bukrs
with brdatu = lv_lastdate
with ktansw = p_ktansw
with budat-low = lv_start
with budat-high = lv_end
and return.
10-08-2008 12:46 PM
Hi
This s the syntax for submit u follow like that.
SUBMIT {rep|(name)} [selscreen_options]
[list_options]
[job_options]
[AND RETURN].
10-08-2008 12:51 PM
Can i know the reason why you are using this statement. Is there specific reason to execute the report with DEFECT variant as well as your defined parameters ?
using selection-set 'DEFECT '
10-08-2008 1:00 PM
I have saved the variant as 'DEFECT' as per my required selection screen.In the pgm they have set 4 variants out of which the variant DEFECT is specific for my requirement.
10-08-2008 1:06 PM
submit rabewg_alv01 using selection-set 'DEFECT '
with bukrs = p_bukrs
with brdatu = lv_lastdate
with ktansw = p_ktansw
with budat-low = lv_start
with budat-high = lv_end
and return.
10-08-2008 1:10 PM
10-08-2008 1:16 PM
I think this is the way it actually works. To achieve your requirement you have to combine SELECTION-SET and WITH SELECTION-TABLE. more info here:
http://help.sap.com/saphelp_470/helpdata/EN/9f/dba51a35c111d1829f0000e829fbfe/frameset.htm
10-08-2008 1:21 PM
10-08-2008 1:25 PM
the order here does matter: SELECTION-SET first than WITH SELECTION-TABLE. If it still does not help, than I would suggest to create a variant woithout the fields you want to change dynamically and go for your original idea (SELECTION-SET and all other fields one by one)
10-08-2008 1:31 PM
hi hema,
the values your passing with submit statement are from that report or what?
if your passing the values of calling report, u can do like this.
suppose if you have a select-option say s_uname in the report,
Inside the report, by using EXPORT statement you send the values to the called report.
EXPORT s_uname to memory-id 'key'.
after submit statement you just import the values of the selection screen.
IMPORT s_uname from memory-id 'key'.
Now in s_uname You can find the values of the submitted report selection screeen values.
Hopes this helps you.
Regards,
Shake sha vali
10-08-2008 1:32 PM
hiii
why u r not using export import parameter for this requirement.
i think this will give u correct values
hope it help you.
Edited by: vikalp on Oct 8, 2008 6:05 PM
10-08-2008 1:38 PM
10-08-2008 1:42 PM
like
export burks into memory id 'VIKALP'
AFTER THAT
submit <program name> and return.
in that program.
u define burks same as previous
after that
import burks from memory id 'VIKALP'.
if u r facing any problem then press f1 on import and export.
10-08-2008 2:15 PM
Hi Hema,
Try this code
The code inside the submit report....
REPORT Zsubmit_report.
TABLES: USR21.
SELECT-OPTIONS : S_USER FOR usr21-bname
START-OF-SELECTION.
EXPORT S_USER to memory ID 'USR'.
The following code should be in Calling Program
SUBMIT Zsubmit_report VIA SELECTION-SCREEN AND RETURN.
IMPORT S_USER FROM MEMORY ID 'USR'.
Like s_user, you can import all the parameters and select-options from your report.
Hope this helps you.
Regards,
Shake sha vali
10-08-2008 1:30 PM
why not just use :
SUBMIT program USING SELECTION-SET 'Variant'.
Regards,
Saurabh.
10-08-2008 1:31 PM
or just
SUBMIT program VIA SELECTION-SCREEN
WITH p_1 = text-085
WITH p_2 = text-086
WITH p_3 = text-088.
10-08-2008 2:31 PM
I think you will have to use SELECTION-TABLE as it is a Select option not a parameter.
SUBMIT report1 USING SELECTION-SCREEN '1100'
WITH SELECTION-TABLE rspar_tab
WITH selcrit2 BETWEEN 'H' AND 'K'
WITH selcrit2 IN range_tab
AND RETURN.
There is a sample report in the ABAP help how to use SELECTION-TABLE. Check that you. That might resolve your problem.
Cheers
-Aman
10-08-2008 2:42 PM
Did you try....
DATA: t_rspar LIKE TABLE OF wa_rspar.
CLEAR wa_rspar.
wa_rspar-selname = 'P_IDOC'.
wa_rspar-kind = 'P'.
wa_rspar-sign = 'I'.
wa_rspar-option = 'EQ'.
wa_rspar-low = wa_docnum-docnum.
APPEND wa_rspar TO t_rspar.
SUBMIT rbdagaie WITH SELECTION-TABLE t_rspar AND RETURN
EXPORTING LIST TO MEMORY.