Creating no. of spool requests based on data
Hi all!
I am preparing a smartform showing the schedule deliveries of purchase orders of all vendors within a specified period. A new spool request is to be generated for each vendor's schedule deliveries. How can I raise a new spool request when the vendor no. is changed? Is it possible? If yes,please suggest.
Edited by: Jayasri P. on Apr 21, 2008 12:31 PM
Hi Nehal!
I have passed the parameter of type SSFCRESCL in the function module fm_name(i.e. 2nd f.module in my program).But it's throwing a dump when executing saying that parameter of specified type doesn't allow to pass through this function module an it allows only fields of a particular type .What is the type of LS_COMPOSER?
I have declared the variable as : LS_COMPOSER TYPE SSFCRESCL .
LS_COMPOSER-TDNEWID = 'X'.
CALL FUNCTION FM_NAME
Exporting
t_lfa1 = t_lfa1
OUTPUT_OPTIONS = LS_COMPOSER
TABLES
it_ekko =it_ekko
it_ekpo = it_ekpo
it_eket = it_eket.
What's going wrong with this?
Similar Messages
-
Spool Request contains disrelated data
Dear All
I met a strange issue, the spool reqeust contains disrelated data.
the phenomenon is:
I created a JOB with function fronted. But when the JOB finished, I found other disrelated data in this spool request.
I'm not sure whether one spool request can contain several print requests?
When I create the request at the same time other function create in this spool request?By default, SAP merges forms in existing spool requests with same properties, listed here: [Note 85318 appending documents to existing spool requests|http://service.sap.com/sap/support/notes/85318]. You may force them to go in a new spool request using output parameters when printing the form (see the note).
-
How to create the multiple spool requests for a single report.
Hi gurus,
I have one requirement to be completed , i need to send the out put of the report via mail in pdf format. for that what i did was, iam executing report in background and creating spool request and converting it to pdf and sending the file.
now the problem is, its a customer ledger report, for each customer i need to create a new spool request and send mail to that particular customer, now my dought is how to create multiple spool requests for a single pro and how i need to go about it.
And one more question is can we create a spool request for a report which is running in online.
waiting for inputs frm gurus.Hello,
As per my knowledge for creating new spool id you will have to set
output_options-tdnewid = 'X'.
and then using
job_output_info-spoolids
create a pdf using
call function 'CONVERT_OTFSPOOLJOB_2_PDF'
Rachana. -
Create aging bucket in BEx - based on date variable
Hi everyone,
I have a report for which we need to create account receivable aging bucket to classify arrears (1>29 / 30>59 / etcu2026).
Our solution overall architecture is the following :
Source System (SAP) > BW back end...Multiprovider > Super BEx Query > Universe > Webi Report
BW 7.0
BO XI 3.2 SP3.0
In this report, each bucket is defined by the difference between:
- the Net Due Date (which is the due date of payment of the invoice)
- and the Current Date (date for which the report is run u2013 can be the date of the day or a date in the past)
We can develop this either in BEx or in Webi, but to avoid potential performance issues in Webi, we take the try to develop this in BEx.
As you can easily imagine, this BEx query will be used for many reportsu2026so not only for this specific report.
What weu2019ve done so far:
1- We created a variable to prompt the user with the date he wants to run the report for
- ZTEST is an optional variable, single value, User input, based on characteristic 0CALDAY
2- We developed RKF in BEx
- Key Figure restricted by Amount
- Net Due Date restricted by the variable ZTEST using the between function and an offset (to determine the range)
=> When we save the query we are getting a warning message saying u201CVariable ZTEST for characteristic Net Due Date has been converted to a required entryu201D
Why? (you probably knowu2026) Because my RKF is using a variable with an offsetu2026which automatically turn on my variable as mandatory and no more as optional.
Consequences:
- In BEx: My variable, which is required to be optional (because we donu2019t have to have this field as mandatory for each and every report running on top of this query) is now mandatory.
- In Webi: If I use the variable (funnel in webi), my report is working fineu2026but if I donu2019t use it in the webi report, I get an error message saying u201Cvalue required for ZTESTu201D
o Funnel is configured as optional in the universe designer (so the issue is not coming from here)
=> 2 consequencesu2026same issue
Question: What can we do to keep our bucket logic running in BEx and avoid this variable to become mandatory?
Solutions (potential)
- Create a custom exit routine to work around this issue u2013 how?
- Create CKF/Custom exit to create our bucket (using ZTEST as an entry value to determine the range) and then use the created range in our RKF to restrict the amount u2013 how? Not so easyu2026
- Build the logic in Webi
- Any other suggestions?
Here we are, any advice would be really appreciated
Thank you guys
Regards
HenriHi peeps,
We finally find a solution for this problem! So I can share it with you.
The overall solution is pretty easy to understand.
1st step is to prompt with the user with a 0DATE variable. The date selected becomes a date input for the next step.
The variables is defined as a range [01/01/1900;variable_value)...in order to retrieve the right data set.
2nd step is to use this date to create our aging bucket, dates range.
To do so, we created 4 user exit variables (for each aging bucket).
3rd step is to use these ranges in RKF.
This way you get aging bucket dynamically defined by the user input pretty cool!
Regards
H -
Create column headers in report based on data entered in Form
Hi,
I have a form with following fields being entered into a table: -- a start date for a project and then projected hours required on a monthly basis for X months
Start Date mnth1_resource mnth2_resource mnth3_resource ...
2/12/2011 30 20 80 ...
6/3/2011 80 30 70
3/12/2011 50 70 60
4/10/2011 40 120 90
I would like to create a report (interactive or otherwise) that will provide headers for the actual months of the calendar showing the full range of months to cover the dates included in the data: e.g. if the above data was the only data entered then:
Feb Mar Apr May Jun Jul Aug Sept
30 20 80
50 70 60
40 120 90
80 30 70
Where mnth1 is the month of the start of the project--
Would appreciate any hints on how to accomplish this.
Thanks,
PatHi,
Thanks for the response. I see how a crosstab type report works great for data that is static and all in the table, however, in my case the issue is that the columns will vary depending on the start date of the project. So even though the user is only entering 12 months of projection, the total number of columns will depend on the start date of the latest project. For example, if a project does not start till June of 2011 and goes out 12 months, the actual column headers will need to go out to May 2012. Likewise the first column will be dependent on the earliest start date month-- like Feb 2011 in the sample data.
Pat -
Best way to trigger Concurrent Request based on dates from query output
Hi
I have a reqmnt to automatically submit a concurrent program, by querying the dates from a backend table which changes with time.
Which is the best/easier way to do this? Any suggestions?
Thanks.via a plsql concurrent programs that calls fnd_requests.submit
-
How may spool request can I create in the backend?...
Hi Experts,
How may spool request can I create in the backend? If yes, is there anywhere in the system can I set this value to increase number of spool request per user.
Is there any condition which can prevent me create a new spool request?
Yes all of the answer above is answered, so is there any offfical document from SAP states them.
Thanks!
- Anthony-Thx for the feedback. But, in fact, what was the real issue, originally?
I forgot to inform you of that:
1) [Note 193638 - Calculating spool number from file names as of 4.0A|http://service.sap.com/sap/support/notes/193638] (indicates the algorithm of UNIX file names). This note also indicates "For Release 4.0A, the maximum spool number has been increased from 99000 to 2000000000. The maximum number of output requests per spool request has been increased to 32767 as well."
2) I think I forgot one of your initial questions:
> Is there any condition which can prevent me create a new spool request?
By default, SAP tries to append pages to existing spools with same characteristics. If they are always different, a new spool request is always created. So, you may change some characteristics so that they are identical and SAP will reuse existing spools. See rules in [Note 85318 appending documents to existing spool requests|http://service.sap.com/sap/support/notes/85318]. -
Creating single spool request for printing all shop floor papers
Hello PP Gurus,
We are printing shop floor papers at the time of releasing production order using txn CO02. It creates individual spool request for printing different shop floor papers in the same orders . eg Pick list, goods receipt list etc.
Is it possible to do the cofiguration setting to create only one spool request for all the different SF papers belong to same order.? If yes, please let me know the steps for customising this.
Thanks for your help in advance.
Regards & Thanks
Rajesh D.In transaction OPK8, in forms uncheck the 'New List' check box for the List.
Regards
Ramanujan -
Dear experts ,
My requirement is ,displaying the spool requests according to user name ,date created ,and Title.for that i am using the following two function modules.
RSPO_RINIT_SPOOL_SP01
RSPO_RDISPLAY_SPOOLREQ
i appended the title of spool request to the internal table and passed that interanal table to RSPO_RINIT_SPOOL_SP01 ,up to now its working fine .but what my requirement is ,i should pass the username and date through selection screen.in the same way i have appended data from the selection screen to respective internal tables and passed through the internal table.if i give wrong 'username ' in selection screen it should not display any spool job.even though its showing spool requests based on title.what was wrong?please help me out.
Thanks and regards
naresh bammidiHi Naresh,
Use below report for your porpose.
TABLES : RQIDEN_T,RQOWNE_T,RQCRED_T,RQTITL_T.
SELECT-OPTIONS : s_spool for RQIDEN_T.
SELECT-OPTIONS : s_owner for RQOWNE_T.
SELECT-OPTIONS :s_date for RQCRED_T.
SELECT-OPTIONS : s_rqtitl for RQTITL_T.
type-POOLs : slis.
data : lt_SPORQ TYPE TABLE OF tsp01sys,
ws_SPORQ TYPE tsp01sys,
goto_sel.
data : lw_sel TYPE SLIS_SELFIELD.
data: lt_sysid type TABLE OF ALSYSID,
ws_sysid type ALSYSID.
ws_sysid-SYSID = SY-SYSID.
append ws_sysid to lt_sysid.
CALL FUNCTION 'RSPO_RINIT_SPOOL_SP01'
EXPORTING
SAVEFLAG = 'A'
SUMMARY = 'X'
LOCAL = 'X'
OWNER = ' '
CLIENT = ' '
RQNONE = 'X'
RQPROC = 'X'
RQSUCC = 'X'
RQERR = 'X'
PJPROC = 'X'
PJSUCC = 'X'
PJPROB = 'X'
PJERR = 'X'
TABLES
SYSLIST = lt_sysid
S_RQIDEN = s_spool
S_RQOWNE = s_owner
s_rqcred = s_date
s_rqtitl = s_rqtitl.
call function 'RSPO_RDISPLAY_SPOOLREQ'
exporting
use = ' '
importing
goto_sel = goto_sel
TABLES
SPORQ = lt_SPORQ
OUTRQ =
changing
rs_selfield = lw_sel
exceptions
others = 1.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
Thanks,
Vijay -
HotNews correction for Y2010 spool request error available
Dear gurus,
I became aware of [SAP Note 1422843|https://service.sap.com/sap/support/notes/1422843] which has affected all my systems's spool request reorg jobs.
It is currently release and patch level independent, so you will all be affected by it as well.
You can verify this via entries in table SP01 field RQDELTIME = 2099*
As a kernel patch might take a while (also to download, install, test, etc...) there is a workaround attached to the note until you get there.
Cheers and best wishes for the new years until 2099..
Julius> ...and the variant provided in this note 1422843 doesn't clean at all....
Yes, it does not "clean" the spool requests out of the system - it corrects the deletion date symptom so that your reorg job will pick them up again. Dependent on your config, this might take a few days to become "cleaned", as they were before as well.
Another option is to reorg the spool requests based on the creation date alone. This works fine for "smaller" systems and will protect the spool overflow and number range problem. It will however not correct the other less critical symptoms, so applying the kernel patch at some stage soon is recommended anyway.
Cheers,
Julius -
Account statement printing - single spool requests
Dear SAP experts,
We would like to use print program RFKORD10 for correspondence type SAP06 (account statements for customers) to print account statements for a range of customers, so in mass processing. I see that the standard behaviour of the program is to put the output in 1 spool request.
Is there any possibility to create a single spool request per account statement / customer? This would be helpful when converting spool requests to a PDF file, in order to send the statements by email.
Regards,
MarkHi Khanna,
I tried that option at first place only. It results in multiple Print Popups. I want to avoid this. For all spool print requests, I want to show ONLY ONE Print Popup.
Thanks. -
Retrieving Deleted Spool Request
Hi,
We are running R/3 45B on the iseries and we had the same problem from Note 1422843 - Wrong deletion date in spool request
I ran the report RSPO2010 to change the deletion date in R/3 PRD excluding 9 users to keep their year end reports.
I then ran RSPO0041. I thought I read the note 1422843 correctly but I ended up deleting every spool request up the date 1/7/2010. Ran with the variant delete all request with min age 8 days.
Is there anyway of getting the spool request back that were deleted?
Is there a table with a deleting flag that I can just uncheck?
I do have a backup - Are there just a couple of tables I can restore to my Q&A system - Can't do full DBcopy at this time.
Regards,
BrianHi Brian,
tja, the stuff is unfortunately deleted now ...
There is no mark to unmark or similar.
The most stuff of a spoolfile is in TST1 - but there should be a few more tables - I didn't investigate this by now -.in my mind, it is a solvable issue with the restore of "let's say 5 tables" to QAS ...
Regards
Volker Gueldenpfennig, consolut international ag
http://www.consolut.net - http://www.4soi.de - http://www.easymarketplace.de -
Creating the spool request for the internal table data
Hi..
I am little confused with the function module used for creating the spool request.
well...I am practicing the ALV report and sending the that report to the spool.
I ve used the FM SLVC_TABLE_PS_TO_SPOOL.
this is the way i defined the internal table.
Data:
begin of imat occurs 0,
matnr like marav-matnr,
maktx like marav-maktx,
matkl like marav-matkl,
ntgew like marav-ntgew,
gewei like marav-gewei,
end of imat.
data i_lines type sy-tfill
and i declared..
describe table imat lines i_lines.
then i given the value for i_file_length as i_lines in the export paramet of the FM SLVC_TABLE_PS_TO_SPOOL.
CALL FUNCTION 'SLVC_TABLE_PS_TO_SPOOL'
EXPORTING
i_file_length = i_lines
IMPORTING
E_SPOOLID = spoolid
tables
it_textdata = imat
when i executed it shows the list and wen going back it shows the runtime error as
CALL_FUNCTION_CONFLICT_LENG - Type conflict when calling a function module (field length).
please provide me some solutions.
thanks in advance.
etienne.Hi satyajit,
Thanks for your response....but the fields in my internal table "IMAT" is not compatible with the structure LVC_S_1022 as it has it componenrt - LINE.
so how can i define my internal table IMAT as type lvc_s_1022 as you suggested.
thanks in advance.
etienne. -
Hi friends,
as per the old message I am trying to create a spool request which further will be downloaded to PDF format. I am facing a problem, as per message when I try to do write in worte_perform I am receving ABAP dumps with Illegal page number
anyidea why is it so .
Thanks
Lakhbir
data: loc_dest like pri_params-pdest .
clear : wf_listname , loc_dest , wf_listtext .
move: 'List name' to wf_listname .
move: 'List header text' to wf_listtext .
select single spld into usr01-spld from usr01 where bname eq sy-uname .
if sy-subrc eq 0 .
move: usr01-spld to loc_dest .
endif .
call function 'GET_PRINT_PARAMETERS'
exporting
destination = loc_dest
copies = wf_copies
list_name = wf_listname
list_text = wf_listtext
immediately = ' '
release = ' '
new_list_id = 'X'
expiration = wf_days
line_size = 200
line_count = 65
layout = 'X_65_200'
sap_cover_page = 'X'
receiver = 'SAP*'
department = ''
no_dialog = 'X'
importing
out_parameters = wf_params
valid = wf_valid.
if wf_valid <> space.
new-page print on parameters wf_params no dialog.
perform write_summary .
new-page print off.
endif .
within the write_summary do a normal write operation.
loop at <itab> .
write:/
endloop .We encountered a similar problem on 4.6C using a custom BAPI to save invoices to PDF for an internal web app. We used a BDC/call transaction to access the output function from there. This was only supposed to be a temporary workaround but has been working and we probably won't revisit until our next upgrade. Hopefully this idea will help on your version, if so I am new here and need points!
*Generate Transaction
PERFORM dynpro USING :
'X' 'SAPMV60A' '0101' ,
' ' 'VBRK-VBELN' v_invoice ,
' ' 'BDC_OKCODE' '=DRCK' .
PERFORM dynpro USING :
'X' 'SAPLVMSG' '0110' ,
' ' 'DNAST-KSCHL' v_kschl,
' ' 'BDC_OKCODE' '=STAR' .
SELECT * UP TO 1 ROWS
FROM nast WHERE objky = v_invoice
AND vstat = '1'
AND kappl = 'V3'
AND kschl = v_kschl
AND aktiv = space.
ENDSELECT.
IF sy-subrc = 0.
PERFORM dynpro USING :
'X' 'SAPLSPO1' '0300' ,
' ' 'BDC_OKCODE' '=YES' .
ENDIF.
PERFORM dynpro USING :
'X' 'SAPLVMSG' '0100' ,
' ' 'NAST-LDEST' 'TD06',
' ' 'NAST-DIMME' space,
' ' 'NAST-TDOCOVER' space,
' ' 'NAST-TDRECEIVER' space,
' ' 'NAST-DELET' 'X',
' ' 'BDC_OKCODE' '=STAR' .
CALL TRANSACTION 'VF03'
USING i_bdcdata
MODE v_mode
UPDATE 'S'
MESSAGES INTO i_bdcmsgcoll. -
Creating spool requests using smartforms
hi folks,
I need help in this area...
I have an ABAP print program that I run to create monthly statements. There are two categories while running the monthly statements identified by the code '6' or '7' Now, i have to create separate spool requests so that while running the print program for these monthly customers.
How can I do this?
SanthoshOk, first lets say that ACCITAB has the records that are printed in the main window of the form. The number of pages for each customer depends on how many records are present in the ACCITAB for the customer.
For example.... ACCITAB.
<b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
1234 08/26/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
1234 08/27/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/21/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/22/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/23/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/24/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/25/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
5678 08/26/2005 <b>Customer Invoice Date Passed Due</b>
1234 08/25/2005 $1.00
1234 08/26/2005 $1.00
1234 08/27/2005 $1.00
5678 08/21/2005 $1.00
5678 08/22/2005 $1.00
5678 08/23/2005 $1.00
5678 08/24/2005 $1.00
5678 08/25/2005 $1.00
5678 08/26/2005 $1.00
.00
Lets say we have two customers in our table, customer 1234 has only two records associated with him, customer 5678 has like 75 lets say. Here you will need to loop at this table and count how many records are there for each customer and store it in another internal. Maybe you can have a separate internal table for each category.
Types: begin of titab,
kunnr type kna1-kunnr,
count type i,
end of titab.
Data: itab_1 type table of titab with header line.
Data: itab_2_5 type table of titab with header line.
Data: itab_6_M type table of titab with header line.
One for 1 pagers, one of 2-5 pagers, and one for 6 and more pages.
Now loop thru ACCITAB and at the end of a customer you need to write a record to one of these tables with the record count. Use the AT END statement. You will need to determine the maximum number of printed lines that your form handles in the MAIN window. Example, how many printed lines does it take to make the form go to the next page. You need to find what this number is.
When you have this number, now you can do some logic which will split the customers into there categorys.
Let's say that the max is 50 lines per page.
Data: counter type i.
LOOP AT ACCITAB.
counter = counter + 1.
at end of kunnr.
IF counter < '50'.
itab_1-kunnr = accitab-kunnr.
itab_1-count = counter.
append itab_1.
elseif counter => '51'
and counter =< '250'.
itab_2_5-kunnr = accitab-kunnr.
itab_2_5-count = counter.
append itab_2_5.
elseif counter => '251'.
itab_6_m-kunnr = accitab-kunnr.
itab_6_m-count = counter.
append itab_6_m.
ENdif.
clear counter.
endat.
ENDLOOP.
Now you have the customers split out into separate internal tables depending on how many pages for thier statement. Now you can start printing.
call fucntion 'OPEN_FORM'.
Loop at itab_1.
* Do the logic which prints your form.
endloop.
call fucntion 'CLOSE_FORM'.
call fucntion 'OPEN_FORM'.
Loop at itab_2_5.
* Do the logic which prints your form.
endloop.
call fucntion 'CLOSE_FORM'.
call fucntion 'OPEN_FORM'.
Loop at itab_6_m.
* Do the logic which prints your form.
endloop.
call fucntion 'CLOSE_FORM'.
Please remember to award points for helpful answers. Thanks.
Regards,
Rich Heilman
Maybe you are looking for
-
I am checking KKS1 report(testrun for period 7 2011), i noted the variance % column not reflecting right % , may i know why? For example for process order 100028687 the variance % compare with actual cost should be 8.6% but shown as 0% please guid
-
Hi Am able to send idoc successfully from ecc 6.0 but i can see them in target system dont know where am mistaking in Ale settings or where pls help me out its bit urgent requirment. Regards Meeta
-
GR For Subcontracting PO using BAPI
Dear Experts, I m using BAPI_GOODSMVT_CREATE this BAPI to create GR for Subcontracting PO , Here i want to give my own values in BOM component with 543 mov.type but its not working. And GR for normal PO is working fine.But for Subcontracting its not
-
I am planning to buy an ipad mini, please suggest me whether its the right choice to go for or not ? Hows the display?
-
Dynamic Client Exception - Need help
Hi, Need help....... I am getting following exception, when I run my dynamic client. Attached below is my code as well as WSDL. Thanks in advance.. Regards -Shakeel [java] javax.xml.rpc.JAXRPCException: failed to invoke operation 'Print' du e to an e