Connecting spool to a job
Hi all,
Is there any way of determining the background job which generated a spool.
We ran a transaction in background mode which generated a spool. I would like to check from the spool which background job created it. i.e. from SP01 or so.
Also any way to determine how much time it took for the spool list to generate from spool information.
Please advice.
Regards,
Aditya
Hi,
GOTO sm37 or SM36 Press execute or scheduled job.
U will get the list of job scheduled and also the spool created, time taken for that job etc.
Thanks & Regardsm,
Judith.
Similar Messages
-
How to send a job log/Spool once the job completed?
Could you please help me how to send a job log/Spool once the job completed.
There was an option is available System Send mail to send a mail once the job completed . So could you please help me how we can send a job log using this option .
I have tried the below but i didn't get any mail . Could some one help this please !
For example :
Job chain name : Test_spool
Step1 : Reportstep
Job definition u2013 XXX_YYY
Step2: Mailstep
Job definition: system_mail_send
Expression : Reportstep,job<(what i need to mention here )>:reportstep/log.txt
Check the ablove mentioned is correct and correct me , still i didnu2019t get the log in the mail please .
Thanks
RamkumarHi Ram,
I need your help on getting mail alert with log file.
here is how i have provide the parameter valure for job definition: system_mail_sent.
Step1 with one job1 and step2 with one job1
In step2 , i have included the job definition to send mail. with below parameter.
Relative Job: Step 1, Job 1
Job File: step 1, job 1: step 1/log.txt
Please let me know if the above method is correct or not.
NOTE: mail server and from address are configured.
Thanks,
Karthik -
Create spool for background jobs which uses submit statement
Hi Gurus,
I have a quick question regarding the backgroud jobs. When we run a program in the background , it should create a spool for us, but, the problem comes when I am running a program in the background, its not creating the spool. This program uses SUBMIT statement. This program collects the data and it will submit to the other program and then retuen. In this case, its not creating a spool. Its very important for us to look at the spool for this program. Does anybody cam across this kind of problem? I need ur inputs.
Thanks in advance, <REMOVED BY MODERATOR>
Regards,
Srinivas.
Edited by: Alvaro Tejada Galindo on Mar 18, 2008 4:31 PMhi check this link ...
Scheduling a submitable program as a background task with the number number in a background request name. After scheduling, the background task is completed by function module JOB_CLOSE and released immediately.
DATA: number TYPE tbtcjob-jobcount,
name TYPE tbtcjob-jobname VALUE 'JOB_TEST',
print_parameters TYPE pri_params.
CALL FUNCTION 'JOB_OPEN'
EXPORTING
jobname = name
IMPORTING
jobcount = number
EXCEPTIONS
cant_create_job = 1
invalid_job_data = 2
jobname_missing = 3
OTHERS = 4.
IF sy-subrc = 0.
SUBMIT submitable TO SAP-SPOOL
SPOOL PARAMETERS print_parameters
WITHOUT SPOOL DYNPRO
VIA JOB name NUMBER number
AND RETURN.
IF sy-subrc = 0.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
jobcount = number
jobname = name
strtimmed = 'X'
EXCEPTIONS
cant_start_immediate = 1
invalid_startdate = 2
jobname_missing = 3
job_close_failed = 4
job_nosteps = 5
job_notex = 6
lock_failed = 7
OTHERS = 8.
IF sy-subrc <> 0.
ENDIF.
ENDIF.
ENDIF.
https://www.sdn.sap.com/irj/sdn/advancedsearch?cat=sdn_all&query=backgroundsubmit&adv=false&sortby=cm_rnd_rankvalue
sy-subrc Meaning
0 Background task scheduled successfully.
4 Scheduling cancelled by user on the selection screen.
8 Error during scheduling, i.e. when accessing JOB_SUBMIT internally.
12 Error in internal number assignment.
regards,
venkat.
Edited by: venkat appikonda on Mar 18, 2008 6:32 PM -
The connection factory name for jobs must be "JobQueueFactory
Hi Experts
Can you plase help me to reslove this issue
Caused by: com.sap.engine.services.deploy.container.DeploymentException: Deployment of jobs in application [backgrounjobear] failed, reason is : [Job "BackGroundJob" of bean "BackGroundJob" does not have a connection factory name. The connection factory name for jobs must be "JobQueueFactory".]
while depling MessageDrivenBean 3.0 getting this.
Any help would Greatly appricated.
Thanks
ABHi All,
I am also getting similar error i.e.
Job "TestScheduler" of bean "TestScheduler" does not have a connection factory name. The connection factory name for jobs must be "JobQueueFactory".
Steps that I have followed are bit different from what is mentioned in document "SAP NW Scheduler for Java" as I am working in 7.3
a) Created EJB Project
b) Created Message Driven Bean(JobSchedulerMDB.jav)
c) Created SchedulerJob(TestScheduler.java)
I dont see application-j2ee-engine.xml ; but have
ejb-j2ee-engine.xml
ejb-jar.xml
job-defination.xml
with following xml in them
ejb-j2ee-engine.xml
<?xml version="1.0" encoding="UTF-8"?>
<ejb-j2ee-engine xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="ejb-j2ee-engine_3_0.xsd">
<enterprise-beans>
<enterprise-bean>
<ejb-name>JobSchedulerMDB</ejb-name>
<jndi-name>JobSchedulerMDB</jndi-name>
<bean-props>
<property>
<property-name>destination-name</property-name>
<property-value>JobQueue</property-value>
</property>
<property>
<property-name>connection-factory-name</property-name>
<property-value>JobQueueFactory</property-value>
</property>
</bean-props>
</enterprise-bean>
</enterprise-beans>
</ejb-j2ee-engine>
ejb-jar.xml
<?xml version="1.0" encoding="UTF-8"?>
<ejb-jar xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:ejb="http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" version="3.0">
<display-name>
JobSchedulerEJBProject </display-name>
<ejb-client-jar>JobSchedulerEJBProjectClient.jar</ejb-client-jar>
</ejb-jar>
job-defination.xml
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<job-definitions>
<job-definition name="TestScheduler"/>
<enterprise-beans>
<enterprise-bean>
<ejb-name>JobSchedulerMDB</ejb-name>
<jndi-name>JobSchedulerMDB</jndi-name>
<resource-ref>
<res-ref-name>JobQueueFactory</res-ref-name>
</resource-ref>
<message-destination-ref>
<message-destination-ref-name>JobQueue</message-destination-ref-name>
<jndi-name>JobQueue</jndi-name>
</message-destination-ref>
</enterprise-bean>
</enterprise-beans>
</job-definitions>
Please help me in this -
Dear Gurus,
I have problem with spool request. I have scheduled BG job for every day period and thist job generate spool.
This job is writing values to the same spool number every day for a mounth. This work correctly for seven days
In eighth day the same spool number was attached to this job, but values in this spool were from another job. And every jobs which were created in last with this spool number have incorrect values of spool too.
It looks like this spool was rewrite by another job. I don´t know ho to prevent it.
Regards
Jakub VaněkThats very weird... so when you open the spool attached to the job it shows the result of a spool created by a different job with the same number?
Check the spool number range maybe?... Also check for consistency in TEMSE
Regards
Juan -
7510 e printer looses wifi connection after each print job;
7510 e printer looses the wifi connection after each print job; only switching wifi off and back on at the printer touch screen makes it reconnect. Tried more or less everything, including downloading updated software for the printer. Wifi router (unfortunately) is provided by internet provider. WPA2.
It sounds like the printer may have an unstable wireless connection.
What brand and model is the router?
Have you tried setting a static IP address? I recommend setting a static IP address as it can resolve a lot of networking issues with printers in general.
The steps to do this are located in step 6 of this document from HP.
↙-----------How do I give Kudos?| How do I mark a post as Solved? ----------------↓ -
How to get spool from background job run?
Hello,
I have this situation and need help on how to resolve:
I have RFC FM which called from another system, in that FM I am submitting BDC section as a batch job by report RSBDCSUB. The problem is that this job may run for 1 or 2 hours and my RFC call will be close by that time. How can I bring the result of my batch job run back to the calling system in this case? Will appreciate any hints.
Thank you,
GlennHi
After you the Job completes. Use the spool ID and fetch the Spool list using the report RSPOLST2.
You can download the spool job using the Function module RSPO_DOWNLOAD_SPOOLJOB.
Thanks
Dev -
Write to spool even when job abends?
There's got to be a way to do this, but I can't seem to find it. I have several background jobs, each of which writes some diagnostic information to the spool. That diagnostic information would be most useful in cases where the job terminates unsuccessfully. But, in those cases, the spool is never saved, and all that information is lost.
I know I can write to the job log instead of the spool, but is there a way other than the log to obtain\show that information? Assume that my program is robust enough to capture all error conditions before terminating.Hello Chris,
I'm sure you might be knowing this, but shall post it here anyways, just in case it skipped your mind.
When you run a background job, the job will abend when either of the following types of message are issued in the program:
1. Warning Message ( Type W )
2. Error Message ( Type E )
3. Abend Message ( Type A )
4. Short Dump Message ( Type X )
In case of either an Abend Message or a Short Dump Message, the entire spool list is erased and thereafter unavailable.
However, in case of either an error message or a warning message, the contents of the spool till the point where the message has occurred are retained.
So, in your case, I suspect that there are some abend messages in the program, issued upon erroneous conditions. If you could change them to ERROR messages (or WARNING messages as you deem appropriate), the spool list is not destroyed.
For your further understanding, I have included the following code snippet.
=======================================================
do 10 times.
write : / sy-index.
case sy-index.
when 3.
message s702(bctrain).
when 5.
message i702(bctrain).
when 7.
message w702(bctrain). " or message e702(bctrain).
endcase.
enddo.
=======================================================
The above program, when scheduled as a background job will get abended, but will retail the spool list :
1
2
3
4
5
6
7
After 7, the warning message abends the job and no other numbers are printed.
Hope this explanation would help you overcome your problem.
Regards,
Anand Mandalika. -
Email multiple spools from background job - SM36 using Spool List recipient
I create a background job using Spool List Recipient to email me the reports. The program that I scheduled to run creates 2 spools. When the spools are sent via email, only the last spool is sent.
Please advise on how I can get the 2 spools sent via email.i would not use the Spool List recipient from Job and use the function RSPO_SPOOLJOB_TO_OFFICE in your Program instead.
tell me if it helps.
Regards,
Laurent -
Multiple ALV lists in a single spool of a job
Hi All,
Executing a custom program in background generates 2 lists in two different spools.
First list - ALV Grid displayed as ALV list
Second List - ALV Blocked List.
Though both the Spool request numbers generated during the execution of the program are displayed in the JOB LOG of the background job,only the latest spool(ALV Blocked List) is saved under this job.
We should go to Tx:SP01/02 to view the First list(ALV Grid) generated in the first Spool request.
Can someone tell me how to get both the lists in a single spool request..(Programmatically)
Or let me know if there is a way to display both the spool numbers in the Spool list of the job in SM37.
Thanks in advance.
HemanthHi Hemanth,
maybe you can have a look at the function RSPO_INSERT_SPOOL_CONCATENATE. There is a documentation in the function module transaction.
Regards
Frédéric -
Teradata destination ODBC connections failing in SSIS job
Windows Server 2012 R2
SQL Server Integration Services 2012
Teradata 13.10.00.14, Driver 14.10.00.06
We have a situation where ODBC connections to Teradata destination database keep getting errors from time to time, not every night though.
Some nights regular load jobs execute successfully and sometimes they get errors "There was an error trying to establish an Open Database Connectivity (ODBC) connection with the database server." -
one or more component failed validation.
The faulty component is usually different, not the same every time. Package may also differ. There are 4 packages starting parallelly at the same time, each having 1 or 2 sequences of dataflows and sql tasks (about 60 dataflows and 40 sql tasks in total in
those packages). Packages have been migrated from DTS to SSIS and this kind of error-situation has never occurred before.
So we checked what happens on the Teradata side - many simultaneous sessions, validation sessions at first then TPT Load and ODBC sessions, but the number of concurrent open sessions never exceeds something like 30-40. And there is a parameter in Teradata indicating
that max allowed sessions is 120.
Two different kinds of connection managers used - Teradata Connection Manager, used in Attunity Teradata Destination component for TPT Loading and ODBC Connection manager to execute SQL Tasks and also for loading to Teradata destination tables in case of low
number of records being transfered.
TPT Loads take 14 sessions each, ODBC destination and validation sessions apparently 1 per validation/component.
What could be the reason for this error? Where to look, what to check?
Thanks for any advice!Sorry the information given doesnt help much to understand the root cause. Anyways something you could do is to set delay validation to true so that actual error you will get at runtime rather than a validation failed message as above. One more thing you
can try is running packages one at a time and see if error occurs. Also see if multiple packages running in parallel are using same object.
Please Mark This As Answer if it solved your issue
Please Vote This As Helpful if it helps to solve your issue
Visakh
My Wiki User Page
My MSDN Page
My Personal Blog
My Facebook Page -
Hi Experts,
In my progra I have used SUBMIT to a standard ABAP program.
Now, this standard porg is getting calledin a loop. So, if somehow a set of worng entry gets into the SubMIT then the standardd program logs error in the job log and even though the spool icon comes up, though I am not able to ecpand the spool.
Kindly guide how can I achieve this.
THanks a lot in advanvce.
UditHi,
Get the spool number from TSP01 based on the attributes viz. Owner of job, Start date, Spool description etc.
Then use FM "RSPO_DOWNLOAD_SPOOLJOB" to download the spool.
Wrt the error of going in loop, you need to ensure that it doesnt get into a loop. Change your program accordingly.
Thanks,
Best regards,
Prashant -
Were do I get the relation spool device batch job/programs
Hi there,
I need to know what batch jobs and what SAP programs/reports ... are related to specific spool devices.
Our business need: we need to replace some old spool devices which are used for some batch jobs, SAP programs... so we need a list of them.
Can anybody tell me what tables, reports, tcodes... are helpfull for this?
Thanks in advance!Hi Alwina,
thanks you for your reply - this helps me for spool request which are created by batch Jobs (only running in Background?!).
What about spool request which are created by a user in dialog or when the output device is coded in source code of a ABAP program (I don't know if this is possible, i am not an ABAP developer)?
Does the report BTCAUX05 (note 1145265) helps me here, too?
Thanks -
How to send a job log/Spool once the job completed in an other Jobchain
I have a Jobchain which raises events when Job goes to status error.
After that a job starts which sends a mail. In this Job I have the parameter:
raising_job_id:
=waitEvents.NSN_JOB_ON_ERRORO.raiserJobId so I can pass the Job ID and send it in the mail.
But how can I also pass the Joblog of the errorjob to the sending mailjob ?
relative_job_id and loblog parameters from system_mail_send job does not work because it's not in the sam Jobchain.
Do I have to use some pre/post running actions ?
I'm not familiar with Java programming
Br
UweHello,
Then this is your lucky day! Since you already have enough knowledge to get the job id from the raiser event you are already half way there! This is because the System_Mail_Send job also understands an arbitrary job id as a RelativeJob. So if you pass the found job id into the RelativeJob parameter and * into the JobFile parameter all output files from the failed job will be send out.
Regards Gerben -
Spool Request in job scheduling
Hi All,
I have scheduled one report in background. But in the spool I am not getting the display of the output in proper manner.
The columns are displayed on two lines.
Please tell me how can I get all the columns in one line. I tried by setting the width of the spool request to the highest value.
The output format which I am getting in the spool is as follows.
Sales Order Number SO Date SOLD TO
VALUE CURRENCY DELIVERY NUMBER DELIVERY DATE MAT GRP
22502214 31.07.2008 OOO"UNIQUE PHARMACEUTICAL LABORATOR
2,430.00 USD EOU
60004962 23.09.2008 ALSHIFA SCIENTIFIC DRUG BUREAU
2,295.00 USD DEPB
60004962 23.09.2008 ALSHIFA SCIENTIFIC DRUG BUREAU
2,295.00 USD DEPB
60004962 23.09.2008 ALSHIFA SCIENTIFIC DRUG BUREAU
2,250.00 USD DEPB
60004962 23.09.2008 ALSHIFA SCIENTIFIC DRUG BUREAU
405.00 USD DEPB
60004962 23.09.2008 ALSHIFA SCIENTIFIC DRUG BUREAU
Please reply.
Thanks in Advnce.
- Neha.Hi,
Even after setting a output device which can hold max characters, am sure its something to do with line-size clause of the report parameter. Try changing the line-size to a highervalue in the report statement of the program like below
report ztest no standard page heading line-size 230 line-count 65.
Regards,
Vik
Maybe you are looking for
-
PDF images visible in Adobe but not Preview or Mac Mail's Quick Look
I have a PDF that I am inserting an ad into. I copy and paste the ad from one PDF into another. The problem I am having is when I have the final 10-page PDF with the ad inserted in it, you can open the 10-page PDF in adobe and the ad will be visible,
-
Lync Online vs Exchange 2013 On Premise
We have Lync 2013 Online and Exchange 2013 SP1/Outlook 2013 SP1 on premise. All work well with RPC over HTTP. We are trying to get MAPI over HTTP (Outlook 2013 SP1 / Exchange 2013 SP1). But it seems that the MAPI over HTTP no longer respects the I
-
Recipts with Clearance method by Automatic clearing are not cleared
Hi, I have a receipt class with a clearance method 'By Automatic Clearing' and have the 'Clearing days' in the Remitance bank set to '1' day. When the receipts are remitted I am expecting them to be auto cleared after 1 day. But the receipts remain i
-
Phantom picture appearing briefly after accessing iPhone with Touch ID or Enter Passcode
Hello everyone, When I access my phone using touch ID, an image that was deleted a long time ago appears for a second then vanishes before my icons and apps show up. This happens randomly. I have deleted the picture and went into the recently deleted
-
hi i backed up my fone today and i am trying to restore my back up however it is retoring everything but my apps WHY IS THAT thanks