Application Development and Automation 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: 
Read only

Submit Report (Regarding Background Processing)

Former Member
0 Likes
1,133

Hi Guru's,

I want help regarding Background Processing.

I have developed a program which is running fine in forground but in Background mode no values are comming.

All values are becomig Zero.

Plz help.


*--- Submit Report for 'COGI' (Postprocessing of Error Records from Automatic Goods Movements)
  SUBMIT coruaffw USING SELECTION-SCREEN '1000'
                  WITH  r_cumul = 'X'
                  EXPORTING LIST TO MEMORY
                AND RETURN.

*---- Get the List
  CALL FUNCTION 'LIST_FROM_MEMORY'
    TABLES
      listobject = it_list_tab
    EXCEPTIONS
      not_found  = 1
      OTHERS     = 2.

  IF sy-subrc = 0.

*--- Convert to Ascii
    CALL FUNCTION 'LIST_TO_ASCI'
      TABLES
        listobject         = it_list_tab
        listasci           = it_asci_tab
      EXCEPTIONS
        empty_list         = 1
        list_index_invalid = 2
        OTHERS             = 3.

    IF sy-subrc <> 0.
*      MESSAGE i000 WITH 'Problem in converting LIST to ASCII'.
    ENDIF.

    DESCRIBE TABLE it_asci_tab LINES w_cogi.

    w_cogi = w_cogi - 5.

  CALL FUNCTION 'LIST_FREE_MEMORY'
    TABLES
      listobject = it_list_tab.

1 ACCEPTED SOLUTION
Read only

gaursri
Active Contributor
0 Likes
1,047

Hi Arbind,

Try using follwing addition

Syntax

USING SELECTION-SCREEN DYNNR

VIA SELECTION -SCREEN

selscreen_parameters

Extras:

1. ... USING SELECTION-SCREEN dynnr

2. ... VIA SELECTION-SCREEN

Further more the background job selection has to be configured properly try using background job creation wizard.

Hope it provides you the desired output of the report.

Have a best day ahead.

9 REPLIES 9
Read only

gaursri
Active Contributor
0 Likes
1,048

Hi Arbind,

Try using follwing addition

Syntax

USING SELECTION-SCREEN DYNNR

VIA SELECTION -SCREEN

selscreen_parameters

Extras:

1. ... USING SELECTION-SCREEN dynnr

2. ... VIA SELECTION-SCREEN

Further more the background job selection has to be configured properly try using background job creation wizard.

Hope it provides you the desired output of the report.

Have a best day ahead.

Read only

Former Member
0 Likes
1,047

Hi,

Actually in foregroung report is giving the correct result.

But my doubt is whether Sumbit Report with Export List to Memory will work in background processing.

Thanks.

Read only

Former Member
0 Likes
1,047

Plz help

Edited by: Arbind Prasad on Jul 6, 2009 6:12 PM

Read only

Former Member
0 Likes
1,047

Anyhow if I am Exporting List to Memory and the going FOr background Processing it's not working

Read only

0 Likes
1,047

Hi Arbind,

You have used return you need to add the addition with.Try this way hope it works

SUBMIT zreport EXPORTING LIST TO MEMORY
                AND RETURN
                WITH P_1 = P_1
                WITH P_2 = P_2
                WITH P_3 = P_3
                WITH S_4  IN S_4
                WITH S_5 IN S_5
                WITH S_6 IN S_6.

Read only

0 Likes
1,047

Hi,

Thanks but I have used with and return.

I have tried a lot and I think Export to Memory will not be working during background Processing.

If u have any hint to submit a report and get the data and disply it using write list .

After that goto SM36 and then try to execute from there then all values will become Zero .

Plz try it once what i have done.

Plz let me know for some solutions.

Read only

0 Likes
1,047

Hai,

You may have to try the Export and Import Statements in your programs. Say for example:

Use the Export statement in your main program.

Export gt_txtedit to memory ID 'STE'. (Example)

And then in the submit program use the Import Statement.

Import gt_txtedit from memory ID 'STE'. (Example)

Hope it helps you.

Best Regards,

rama

Read only

0 Likes
1,047

I can assure you that SUBMIT ... EXPORTING LIST TO MEMORY ... and calling LIST_FROM_MEMORY works OK in background. In my case here I am not using LIST_TO_ASCI though but instead WRITE_LIST to display the list.

So maybe LIST_TO_ASCI has a problem in background, but I cannot imagine why. You would have to investigate further.

Thomas

Read only

0 Likes
1,047

yes, List yo ASCI is having Probelm.

Actually the requirement is Submit a report get the Values in Internal Tables Just i have to count how many rows are there and

then I have to display the no.of Counts.

Suppose for VFX3 there are 3 no. of lines then I have to display only 3.

But the code has to be run in background .

Please Help