How to run ABAP Function Module in Background Wchich Takes Long Time to Run
How to run ABAP Function Module in Background FOR LONG TIME
I am not that experienced with ABAP. I am on SAP BI 7.0. I WANT TO RUN A FUNCTION MODULE
RSDRT_INFOCUBE_DATA_COPY.
I used SE37 and then executed the module, I supplied the parameters on the form which opped-up and then program started running. . Program was however interrupted after 10 minutes by ABAP. How can I run it in background without interruption?
THANKS A LOT.
Hi,
You can call this FM in a program and run that program in background.
Regards,
Raju
Similar Messages
-
How to run ABAP Function Module in Background FOR LONG TIME?
I am not that experienced with ABAP. I am on SAP BI 7.0. I WANT TO RUN A FUNCTION MODULE
RSDRT_INFOCUBE_DATA_COPY.
I used SE37 and then executed the module, I supplied the parameters on the form which opped-up and then program started running. . Program was however interrupted after 10 minutes by ABAP. How can I run it in background without interruption?
THANKS A LOT.Change parameter rdisp/max_wprun_time.
Default value for this is 600 seconds (10minutes).Change it to a time which you think you need for copying infocube data.
May be 5 hours.
PS:You can not run Function Module in background directly,but you can create a Z* program and call that FM from within that program and then run the program in background.
Hope this answers your query. Best of Luck!
Thanks and Regards
Anindya
Edited by: Anindya Bose on Jun 30, 2009 1:24 PM -
The 0co_om_opa_6 ip in the process chains takes long time to run
Hi experts,
The 0co_om_opa_6 ip in the process chains takes long time to run around 5 hours in production
I have checked the note 382329,
-> where the indexes 1 and 4 are active
-> index 4 was not "Index does not exist in database system ORACLE"- i have assgined to " Indexes on all database systems and ran the delta load in development system, but guess there are not much data in dev it took 2-1/2 hrs to run as it was taking earlier. so didnt find much differnce in performance.
As per the note Note 549552 - CO line item extractors: performance, i have checked in the table BWOM_SETTINGS these are the settings that are there in the ECC system.
-> OLTPSOURCE - is blank
PARAM_NAME - OBJSELSIZE
PARAM_VALUE- is blank
-> OLTPSOURCE - is blank
PARAM_NAME - NOTSSELECT
PARAM_VALUE- is blank
-> OLTPSOURCE- 0CO_OM_OPA_6
PARAM_NAME - NOBLOCKING
PARAM_VALUE- is blank.
Could you please check if any other settings needs to be done .
Also for the IP there is selction criteris for FISCALYEAR/PERIOD from 2004-2099, also an inti is done for the same period as a result it becoming difficult for me to load for a single year.
Please suggest.The problem was the index 4 was not active in the database level..it was recommended by the SAP team to activate it in se14..however while doing so we face few issues se14 is a very sensitive transaction should be handled carefully ... it should be activate not created.
The OBJSELSIZE in the table BWOM_SETTINGS has to be Marked 'X' to improve the quality as well as the indexe 4 should be activate at the abap level i.e in the table COEP -> INDEXES-> INDEX 4 -> Select the u201Cindex on all database systemu201D in place of u201CNo database indexu201D, once it is activated in the table abap level you can activate the same indexes in the database level.
Be very carefull while you execute it in se14 best is to use db02 to do the same , basis tend to make less mistake there.
Thanks Hope this helps .. -
Auto message restart job take long time to run
Dear all,
I have configre the auto message restart job in sdoe_bg_job_monitor
but it take long time to run.
i have execute the report i have find out that it is faching records from smmw_msg_hdr .
in the table present 67 laks records are there.
actually it is taking a lot of time while getting data from the table
is there any report or tcode for clearing data in the table.
I need ur valiuble help to resolve the issue.
Regards
lakshman balanaguHI,
If you are using oracle database you may need to run table statistics report (RSOANARA) to update the index. The system admin should be able to this.
Regards,
Vikas
Edited by: Vikas Lamba on Aug 3, 2010 1:20 PM -
NAC Agent takes long time to run
Cisco NAC agent takes long time to popup or run on Windows 7 machine.
The client machine is windows 7, running nac agent 4.9.0.42, against ISE 1.1.1
Any ideas how to reduce NAC Agent timing?Hi Tariq,
I'm facing the same issue with ISE 1.1.1 (268) with Agent 4.9.0.47 for Windows XP clients. I have already configured "yes" to disabled the l3 swiss delay and reduced the httpa discovery timer from 30 to 05 sec but still clients get aprox 2.30 minutes to popup and finished the posture discovery.
Can you please advise if this is the minimum time or what is the minimum time and what are the parameters to set to a minimum time to complete agent popup and posture discovery..?
Is there any option that we can run this on backgroup..?
thanks in advance.. -
Oracle9i reports take longer time while running in web
Hi,
I have developed few reports in Oracle9i and I am trying to run the reports in web. Running a report through report builder takes lesser time compare to running the same report in web using web.show_document. This also depends on the file size. If my report file size(.jsp file) is less than 100KB then it takes 1 minute to show the parameter form and another 1 minute to show the report output. If my file size is around 190KB then the system takes atleast 15 minutes to show the parameter form. Another 10 to 15 minutes to show the report output. I don't understand why the system takes long time to show the parameter form.
I have a similar problem while opening the file in reports builder also. If my file size is more than 150KB then it takes more than 15 minutes to open the file.
Could anyone please help me on this.
Thanks, RadhaThis problem exists only with .jsp reports. I saved the reports in .rdf format and they run faster on web now. Opening a .jsp report takes longer time(file with 600KB takes atleast 2 hours) but the same report in .rdf format takes few seconds to get opened in reports builder.
-
How to call ABAP function module/ class method through web service?
Hi Colleagues,
I need to write an iphone version of current ABAP program. I want to call ABAP method and function module through my iphone so that I can re-use the ABAP APIs.So I choose web service. Can you give me any details information about how to do that?
Thank you very muchHi,
you need to create webservice out of FM. goto SE80 and follow the webservice creation wizard. Finally use webservice url for calling FM (remote enabled) from your iPhone.
Regards,
Gourav -
Take longer time to run sql worksheet
Hi,
I using sql developer for running a script in sql worksheet, it take an endless time to complete running the command, and the command is just a simple query (e.g. begin xxxx end;)
This problem doesn't happen before in my pc. I had try to reinstall the software but still the same. Any one can help me?
I using oracle sql developer v1.5.3
Window 2K SP 4, 512 RAM Intel Pentium 1.8 GHz
Java SE development: jdk 1.6.0_03
ThanksSure it's as simple as you think? How about a SELECT * FROM DUAL ?
What kind of database is this?
Can you see in the Enterprise Manager (or similar) if the database is very busy or something?
Can you verify with another tool if it's related to sqldev or not?
K. -
Hi Friends,
We have a leave record in the following manner:
name date leaves
ABC 01-oct-08 1
ABC 02-oct-08 1
ABC 03-oct-08 1
ABC 04-oct-08 1
ABC 05-oct-08 1
ABC 10-oct-08 1
ABC 18-oct-08 1
ABC 19-oct-08 1
ABC 20-oct-08 1
ABC 25-oct-08 1
ABC 26-oct-08 1
ABC 27-oct-08 1
ABC 28-oct-08 1
and we need an output in the following manner:
output
Name FromDate ToDate Leaves
ABC 01-oct-08 05-oct-08 5
ABC 10-oct-08 10-oct-08 1
ABC 18-oct-08 20-oct-08 3
ABC 25-oct-08 28-oct-08 4
The code for the above mentioned logic is as follows:
=======================================================
=======================================================
procedure KPM_AB_LWP_PROC(p_err_buf OUT VARCHAR2, p_ret_code OUT NUMBER) is
diff number;
prev_date date;
p_prev_date date;
first_date date;
last_date date;
dt date;
total_leaves number := 0;
ecode varchar2(20);
ename varchar2(240);
cursor ab_lwp_cur(process_from_date date, process_to_date date, e_code varchar2) is
select
ab.EMPCODE,
ab.RECORD_DATE,
ab.FIRST_HALF,
ab.SECOND_HALF,
(em.last_name || ', ' || em.TITLE || ' '|| em.FIRST_NAME || em.MIDDLE_NAME) EMP_NAME
from
kpm_hr_absent_record ab, kpm_hr_emp_mst em
where
ab.EMPCODE = em.EMPCODE
and (ab.FIRST_HALF in ('AB','LWP') or ab.SECOND_HALF in ('AB','LWP'))
and ab.EMPCODE like e_code
and ab.record_date between process_from_date and process_to_date;
cursor active_emp is
select empcode
from kpm_hr_emp_mst
where status='Active'
order by empcode;
begin
for emp in active_emp loop
begin
select min(ab.RECORD_DATE), max(ab.RECORD_DATE)
into prev_date, last_date
from kpm_hr_absent_record ab
where (ab.FIRST_HALF in ('AB','LWP') or ab.SECOND_HALF in ('AB','LWP'))
and ab.EMPCODE like emp.empcode;
exception
when others then
prev_date := null;
last_date := null;
end;
dt := prev_date;
FND_FILE.PUT_LINE(FND_FILE.OUTPUT,'Employee' || chr(9) || chr(9) || 'Name' || chr(9) || chr(9) || 'From Date' || chr(9) || chr(9) || 'To Date' || chr(9) || chr(9) || 'Total Leaves');
FND_FILE.PUT_LINE(FND_FILE.OUTPUT,'---------' || chr(9) || chr(9) || '-----' || chr(9) || chr(9) || '----------' || chr(9) || chr(9) || '---------' || chr(9) || chr(9) || '-------------');
while dt <= last_date loop
first_date := dt;
total_leaves := 0;
for m in ab_lwp_cur(prev_date, last_date, emp.empcode) loop
ecode := m.empcode;
ename := m.emp_name;
diff := m.record_date - prev_date;
if diff = 0 then
if m.first_half in ('AB','LWP') then
total_leaves := total_leaves + 0.5;
end if;
if m.second_half in ('AB','LWP') then
total_leaves := total_leaves + 0.5;
end if;
prev_date := prev_date + 1;
else
prev_date := m.record_date;
goto print_leave;
end if;
p_prev_date := prev_date -1;
end loop;
<<print_leave>>
if total_leaves > 0 then
FND_FILE.PUT_LINE(FND_FILE.OUTPUT,ecode || chr(9) || chr(9) || ename || chr(9) || chr(9) || first_date || chr(9) || chr(9) || p_prev_date || chr(9) || chr(9) || total_leaves);
end if;
dt := prev_date;
end loop;
end loop;
exception
when others then
FND_FILE.PUT_LINE(FND_FILE.LOG,'Error: ' || sqlerrm);
end KPM_AB_LWP_PROC;
=======================================================
=======================================================
The problem is that this code takes about 24hrs to run which is not accepted.
Kindly suggest us some other technique to implement the same logic.
For your reference, the KPM_HR_ABSENT_RECORD table has about 3,75,000 records in it.
Also we have created some indexes on certain column as recommended by explain plans.
Thanks in advance
Ankurwith t as (select 'ABC' as nm, to_date('01-oct-08','dd-mon-yy') as dt, 1 as leaves from dual union all
select 'ABC',to_date('02-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('03-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('04-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('05-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('10-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('18-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('19-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('20-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('25-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('26-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('27-oct-08','dd-mon-yy'), 1 from dual union all
select 'ABC',to_date('28-oct-08','dd-mon-yy'), 1 from dual)
-- end of sample data
select nm, min(dt), max(dt), sum(leaves)
from
select nm, dt, max(group_id) over(partition by nm order by dt) group_id
, leaves
from
select nm, dt, case when trunc(dt) - 1 != lag(trunc(dt),1,trunc(dt))
over(partition by nm order by dt)
then rownum
end group_id
, leaves
from t
group by nm, group_id
order by 1,2;Hope this helps.
@Blushadow, thanks very much for the test data.
Regards
Raj
P.S : For more information check this link
http://www.oracle.com/technology/oramag/oracle/04-mar/o24asktom.html
and search for "Analytics to the Rescue (Again)" in that page.
Edited by: R.Subramanian on Oct 22, 2008 4:52 AM
Changed count function to Sum function -
Report Background Engine takes long time
Hi all,
I'm using Reports6i while the db is a 10gXE instance.
When I click for the report, I see RBE starts but nothing happens for about 2-3 minutes; also in task manager I see RBE doesn't use CPU. After those minutes, ther parameter form appears. Even if the report doesn't require parameters, it still takes 2-3 minutes to show something.
I also have other reports made with Reports6i and their behaviour is completely different: they take 2-3 seconds! The difference is these reports work on Oracle 8 instances.
Maybe the problem is the Reports6i-Oracle10gXE interface?Formatting page 1 often means that the query is still executing, not that the page is formatting page 1.
If the report is "Formating page 2" for a long while on a 3 page report (assuming page 2 is not another query in a different report section) it would seem that the query is passing bits of data back to the report a bit at a time.
In this case try adding the ALL_ROWS hint which forces Oracle to retrieve all rows (you optimizer may be set to first_rows) -
How to DEBUG a function module running in background mode? Please help!
Hi Experts,
I am calling a function module in my ABAP code in background module using the following syntax:
CALL FUNCTION 'YBBC2_CREATE_SNAPSHOT' IN BACKGROUND TASK
TABLES
itab_std_format_inv = itab_std_format_inv
itab_snapshot_inv = itab_snapshot_inv.
COMMIT WORK.
If I put the breakpoint in the CALL FUNCTION line and execute the program, the debugger does not take me to the valled function module. This may be because I am running the function module as background task.
I cannot comment this "IN BACKGROUND TASK" statement as well since i am debugging in Quality system where I don't have change access.
So how to DEBUG a function module running in background mode? Please help!
Thanks
GopalHi,
You could try to use the following trick:
(1) Put an endless loop into the coding of your function module where you want to start debugging, e.g.
DATA:
lx_exit_loop(1) TYPE c.
lx_exit_loop = ' '.
DO.
IF ( lx_exit_loop = 'X' ).
EXIT.
ENDIF.
ENDDO.
(2) Call your function module in background task
(3) Call transaction SM50 and search for the background process.
(3) Choose from menu Program/Mode -> Program -> Debugging
Now you the debugger should bring you right to your endless loop. Set lx_loop_exit = 'X' in the debugger and continue (F5 or F6).
<b>Reward points</b>
Regards -
What is the use of CALL FUNCTION MODULE - AT BACKGROUND TASK?
Hi experts,
I found Call functional module in background task will make the FM run at the next commit work as some people said. So I have some questions:
1 if we use COMMIT WORK commend, the pending FM will be called? If there are several FMs called at background task, what is the sequence of them? How many conditions will trigger the running of these FMs?
2 Where can I find the log of this pending FMs? In SAP library, it says there are 2 tables. But I checked these tables and can only find the FM name and user of it. And I can not understand content of these tables. It seems one is for the main information of FM, and the other is for the data of the FM, maybe the parameters.
3 If I call a FM in this way, Can I canncel it before the next commit work in some way?
Finally, thanks for reading and help.HI,
When the COMMIT WORK statement is executed, the function modules registered for the current SAP-LUW are started in the order in which they were registered. ROLLBACK WORK deletes all previous registrations for the current SAP-LUW.
If the specified destination is not available when COMMIT WORK is executed, an executable program called RSARFCSE is started in background processing. By default, this tries to start the function modules registered for a SAP-LUW in their destination every 15 minutes and up to 30 times. These parameters can be changed in the transaction SM59. If the destination does not become available within the defined time, it is recorded in the database table ARFCSDATA as the entry "CPICERR". The entry in the database table ARFCSSTATE is deleted after a standard period of eight days -
Jco Call a Function Module in BackGround
Hello All.
Some one can send me a simple exemplo how to call a ABAP Function Module in BackGround.
Can i set this in Java side?
..or only set the BackGround Work Process in SAP side?
In my java application call the Abap Function Module like this:
client.execute(function);
How to set parameters to execute the function in BackGround.
My rpoblem is when the return the data to java side ...occurs the error TIME_OUT in Dialog WorkProcess.
I need to call in background to better performance and to prevent the TIME_OUT.
Best regards.
Taylor.Hi.
I dont know how to do, but, you can do a previous RFC, this new RFC execute the original function in background mode. I did something like that:
- JAVA: client.execute("RFC_FUNCTION", input, output);
- SAP: RFC_FUNCTION:
CALL FUNCTION func IN BACKGROUND TASK
[DESTINATION dest]
parameter_list
[AS SEPARATE UNIT].
or
CALL FUNCTION update_function IN UPDATE TASK
[EXPORTING p1 = a1 p2 = a2 ...]
[TABLES t1 = itab1 t2 = itab2 ...].
I hope that help you -
How to use this function module on abap hr GET_PDSNR_RANGE
how to use this function module on abap hr GET_PDSNR_RANGE
thankx.PASS INETRNAL TABLE WITH SOME DATA TO TABELLE FOR GENERATING PDSNR SEQUENCE
-
GP: How to keep action sleeping until ABAP function module raises event
Hello experts,
I'd like to develop a gp process which contains a callable objects which keeps the process instance waiting until an abap function module send something like an event.
I don't want to put too much load on the machine and block expensive JCO ressources.
Does anyone have an idea how to solve this?
Thanks very much
StefanHi Mike,
GREAT! Many thanks! Sometimes solutions may be so simple.
For all others who have the same problem a bit more in detail:
In your FM just enter as exception: CX_BO_ACTION_CANCELLED and mark 'Exceptn. Classes'.
Declare your class method with the exception cx_bo_action_cancelled.
In your class method just enter your FM via the 'Pattern'-Button.
The Pattern will show only the Import- and Export-Parameters but not the exception (class).
Regards,
Georg
Maybe you are looking for
-
I'm using the code shown in the sample VI discussed here: http://digital.ni.com/public.nsf/allkb/353A696A3F393D9B86256E8B007A2912 to close all open VIs except my top level VI. My top level VI is actually a separate executable and the sub-VIs are the
-
Specs for editing on MacBook Pro.
Just got CS6. My old MacBook isn't up to the task of editing HD with it. (I used to use Final Cut Pro 6 with little problem). I'm considering getting a new MacBook. Anybody else editing on a MacBook? What do I need to make it run smoothly, and not ha
-
Dual dock no longer pairs/charges BT headset
Since the most recent update (it seems), the dual dock doesn't recognize my Apple BT headset. It doesn't show the charge status on the iPhone like it used to and the actual charge on it has been spotty at best. I just tried dual charging on the "trav
-
Hi, I have a lookup function not retreiving any information. If a create a report in my application called "Rates" and use the same selection as in my LOOKUP function I can see a number, but for some reason it retreives a zero. In my REC statement i
-
Use block processor to perform lookups in alternate HFM app
Hi All, I would like to use the block processor to perform attribute lookups (using functions such as GetCustomTopMember, etc) on an alternate application (ie: not the one that is connected to the FDM app in the adapter). We are pulling data out of o