'Missing parameter with PERFORM' error with a function IN BACKGROUND TASK
I am getting this error when calling a custom function in MIGO user exit ZXMBCU01. When I remove the 'IN BACKGROUND TASK' the function works fine and there are no error messages. When using 'IN BACK...' you can't debug within it to see where the message comes from. I see the message with SM58. I am working in an sap 4.7 environment. I have not found any solutions from google searches.
Here is the statement within ZXMBCU01:
CALL FUNCTION 'Z_UPDATE_MATERIAL_AVAIL_STATUS' IN BACKGROUND TASK
EXPORTING
work_order = xmseg-aufnr.
Here is the code for the function:
FUNCTION Z_UPDATE_MATERIAL_AVAIL_STATUS.
""Update function module:
""Local interface:
*" IMPORTING
*" VALUE(WORK_ORDER) LIKE AUFK-AUFNR DEFAULT '0000000000'
TABLES: eban, resb, aufk.
-Global Types----
TYPES: BEGIN OF t_data,
rsnum TYPE resb-rsnum,
rspos TYPE resb-rspos,
aufnr TYPE resb-aufnr, "Order Number
bdmng TYPE resb-bdmng, "Requirement Quantity
enmng TYPE resb-enmng, "Quantity withdrawn
bsmng TYPE eban-bsmng, "Quantity ordered against this purchase requisition
END OF t_data.
DATA: gt_data TYPE t_data OCCURS 0,
ga_data TYPE t_data.
-Global Variables----
DATA: gv_refused TYPE BAPIFLAG-BAPIFLAG,
gs_caufvd TYPE caufvd,
g_text TYPE t100-text,
gv_objnr LIKE aufk-objnr,
gv_status LIKE bsvx-sttxt,
gv_trig_stat TYPE c.
TABLES RETURNED FROM BAPI
DATA: BEGIN OF xreturn OCCURS 0.
INCLUDE STRUCTURE bapiret2.
DATA: END OF xreturn.
SELECT SINGLE objnr FROM aufk
INTO gv_objnr
WHERE aufnr = work_order.
CALL FUNCTION 'STATUS_TEXT_EDIT'
EXPORTING
flg_user_stat = 'X'
objnr = gv_objnr
only_active = 'X'
spras = sy-langu
IMPORTING
line = gv_status.
IF ( gv_status CS 'REL' ) AND
( gv_status NS 'NMAT' AND gv_status NS 'CNF' AND gv_status NS 'CLSD' AND
gv_status NS 'TECO' AND gv_status NS 'DLFL' ).
SELECT SINGLE *
FROM AUFK
WHERE aufnr = work_order AND
( auart = 'PM01' OR
auart = 'PM02' OR
auart = 'PM03' OR
auart = 'PM99' ).
IF sy-subrc = 0.
SELECT resbrsnum resbrspos resbaufnr resbbdmng resbenmng ebanbsmng
INTO CORRESPONDING FIELDS OF ga_data
FROM resb LEFT JOIN eban
ON resbrsnum = ebanarsnr AND
resbrspos = ebanarsps
WHERE resb~aufnr = work_order AND
resb~bdmng > 0.
SELECT rsnum rspos aufnr bdmng enmng
INTO CORRESPONDING FIELDS OF ga_data
FROM resb
WHERE aufnr = work_order
AND bdmng > 0.
SELECT SINGLE bsmng
INTO ga_data-bsmng
FROM eban
WHERE arsnr = ga_data-rsnum
AND arsps = ga_data-rspos.
IF sy-subrc <> 0.
CLEAR ga_data-bsmng.
ENDIF.
IF ga_data-bdmng = ga_data-enmng OR
ga_data-bdmng = ga_data-bsmng.
"update status - but all items must pass
ELSE.
gv_trig_stat = 'N'.
EXIT. "status won't change so get out now
ENDIF.
ENDSELECT.
IF ga_data~bdmng > 0.
IF ga_data-bdmng = ga_data-enmng OR
ga_data-bdmng = ga_data-bsmng.
IF gv_trig_stat <> 'N'.
CALL FUNCTION 'CO_IH_USERSTATUS_SET'
EXPORTING
I_AUFNR = ga_data-aufnr "'000005000263'
I_USR_STAT_INT = 'E0002'
I_USR_STAT_EXT =
I_SET_INACTIVE =
I_BUF_READ =
I_SPRAS = sy-langu
IMPORTING
E_CHNG_REFUSED = gv_refused
E_CAUFVD = gs_caufvd
TABLES
RETURN = xreturn.
LOOP AT xreturn
WHERE type = 'E'.
ENDLOOP.
IF sy-subrc <> 0.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
RETURN.
ELSE.
READ TABLE xreturn INDEX 1.
CALL FUNCTION 'PI_BP_GET_MESSAGE_TEXT'
EXPORTING
iv_message_id = xreturn-id
iv_message_type = xreturn-type
iv_message_number = xreturn-number
iv_message_v1 = xreturn-message_v1
iv_message_v2 = xreturn-message_v2
iv_message_v3 = xreturn-message_v3
iv_message_v4 = xreturn-message_v4
IMPORTING
ev_message_text = g_text.
ENDIF.
ENDIF.
ENDIF.
ENDIF.
ENDSELECT.
ENDIF.
ENDIF.
ENDFUNCTION.
Does anyone have any ideas? Thank you very much in advance.
Glenn Allen
Software Architect (specializing in SAP)
I'd be starting a process of elimination... perhaps start with an "exit." right after
SELECT SINGLE objnr
FROM aufk
INTO gv_objnr
WHERE aufnr = work_order.
exit. "leave FM NOW
and if that doesn't crash, work down the code down the code in the function e.g. comment out the BAPI_commit call... and / or build a little test harness report to call the Z function in background task... btw, does the ST22 dump point to anything more specific...?
Similar Messages
-
Error creating vendor w/ JCo FM VENDOR_INSERT- Missing parameter w/ PERFORM
Dear all,
I have followed the following thread and found it very useful as we need to create vendors from an external system in R/3 using the JCo as well. We are doing all the steps specified in previous posts and calling FM VENDOR_INSERT but when I execute the function it returns an exception:
JCoException: (104) RFC_ERROR_SYSTEM_FAILURE: Missing parameter with PERFORM.
We have checked and all the needed BAPIs are enabled but we are stuck at this first step. I have tried a variety of things but nothing seems to work. Not sure how I can specify the PERFORM parameter using JCo. Did anyone else fase this issue?
Here is what some of the relevant Java code looks like:
JCoFunctionTemplate tmplt1 = repository.getFunctionTemplate("VENDOR_INSERT");
JCoFunction vfunc = tmplt1.getFunction();
JCoParameterList vparams = vfunc.getImportParameterList();
JCoStructure jcs= vparams.getStructure("I_LFA1");
try
LocalSupplier s = getSupplier1();
jcs.setValue("MANDT", "010");
jcs.setValue("NAME1", s.getSupName());
jcs.setValue("NAME2", s.getSupName2());
jcs.setValue("PSTLZ", s.getSupPostalCode());
jcs.setValue("ORT01", s.getSupCity());
jcs.setValue("LAND1", s.getIdCountry().getIsocode());
jcs.setValue("STRAS", s.getAddress1() +", " + s.getAddress2());
jcs.setValue("MCOD1", "test");
jcs.setValue("KTOKK", "ZKRE");
jcs.setValue("SPRAS", s.getIdmasterSupplier().getIdlanguage().getLocale());
jcs.setValue("STCD1", s.getIdmasterSupplier().getTaxId());
jcs.setValue("TELF1", s.getTelephone());
jcs.setValue("TELFX", s.getFax());
execute(vfunc, destination);
catch(Exception e)
System.out.println(e.toString());
e.printStackTrace();
return;
* Method execute will call a function. The Caller of this function has
* already set all required parameters of the function
public static void execute(JCoFunction function, JCoDestination dest) {
try {
JCoContext.begin(dest);
function.execute(dest);
JCoContext.end(dest);
} catch (JCoException e) {
e.printStackTrace();
Any help from some of view that have succesfully implemented vendor creation using the JCo would be highly appreciated.Hi,
as I just wrote in the previous thread,
don't use function module VENDOR_INSERT.
As written before it is an update task FM. And also it do not check any field validity.
This is the best way to face inconsistencies in the future.
As you have also noticed, troubles and difficulties will come very soon related to the address management.
In standard there is NO FM or BAPI to do so.
The only supported option is via batch-input or idocs. Eventually, LSMW could help
See [note 384462|https://service.sap.com/sap/support/notes/384462]
With ECC 2005, a synchronisation class can help a lot. See class VMD_EI_API.
With ECC 2005 ehp3, you have an eSOA service to create vendor asynchronously. Not all fields are supported.
In other words, just create a BAPI to transfert your own parameters then either make a batchinput which will call XK01/XK02 in batch, either trigger class VMD_EI_API
BR
Alain -
Incorrect parameter with CALL FUNCTION - WE19
hi! All
while creating IDOC through WE19 - Start Inbound it creates IDOC with Status - 64."IDoc ready to be transferred to application" "No filters , No conversion , No version change ."
Incorrect parameter with CALL FUNCTION
This parameter was "MASSAVEINFOS".
but i have Included this parameter in my Function module.
INPUT_METHOD TYPE INPUTMETHD
MASS_PROCESSING TYPE MASS_PROC
NO_APPLICATION_LOG LIKE SY-DATAR
MASSAVEINFOS LIKE MASSSAVINF
whats the mistake i have done.
Regards
KvThat will not be possible KV, as the call to the FM is not being made, as far as i see you have completed the needed settings.
As i do not have access to an SAP system, i suggest that you try below,
1) Go to WE19, enter the IDOC number and F8.
2) In this screen, click on Inbound function module.
3) In the field for inbound function module press F4, it should list your FM name here if all the necessary we42/82/57, BD51 and WE20 have been done correctly.
Another thing that you can try is, on WE19,
1) Idoc Number F8
2) /h - to start Debug
3) Now click on Standard inbound, in the debug mode press F5 once.
4) Now put a break point on all message statement
See where exactly the message of wrong FM is being thrown, it will most probably be after a select statement on one of the tables associated with WE42/82/57/BD51 etc. With this you will where you have missed out.
All the best !!!
Regards,
Chen
Edited by: Chen K V on Mar 18, 2010 8:55 AM -
Need a File Parameter with Browse Functionality in ABAP
Hi
I Need a File Parameter with Browse Functionality in ABAP.
Can anyone help me with logic.
Regards,
SreeCheck below code:
PARAMETERS: p_file TYPE localfile.
DATA: l_path TYPE string,
l_fpath TYPE string,
l_fname TYPE string.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
CALL METHOD cl_gui_frontend_services=>file_save_dialog
EXPORTING
window_title = 'Save to...'
default_extension = '.txt'
initial_directory = 'C:\'
CHANGING
filename = l_fname
path = l_path
fullpath = l_fpath
EXCEPTIONS
cntl_error = 1
error_no_gui = 2
not_supported_by_gui = 3
OTHERS = 4.
IF sy-subrc EQ 0.
MOVE l_fpath TO p_file.
ENDIF. -
I'm trying to create a measurement document with the ABAP function IMRG_WRITE_DOCUMENT invoked by JCo.
Does anyone know which fields must be filled to success? Everytime I try I'll get the error message "Missing Parameter at PERFORM" though I tried to fill every field of the input parameters.
Thanks for your help.
P.S. Does there exist a BAPI function that provides the creation of measurement documents? I didn't find anything.
P.P.S. I'm using the IDES-PLM-System "R03 DMZ IDES Promise".It appears the function module you are calling does not create measurement documents, but rather CHANGE documents. A quick scan in SE84 produced a list that includes MEASUREM_DOCUM_RFC_SINGLE_001 and _002. Take a look at function group IMR0 (zero).
Hope this helps -
Error printing Check - "Missing Parameter Values. Error During Printing"
Dear friends,
Our client is in SAP B1 8.81 Pl07 and is facing an error while printing checks designed in Crystal Reports. As soon as they click on "Print" button, we are getting an error "Missing Parameter Values. Error During Printing".
We have checked the Crystal Reports and all the parameters are given.
Can anyone help me regarding this?
Thanks and regards,
Bharath Shi,
Quoted from Note 1555170
1555170 - Error 'Missing parameter values' printing with CR layout
Symptom
When you print on add any stock transactions document, with Crystal report layout, you receive error message:'Missing parameter values' and then 'Error during the printing; ensure all parameters are defined'
Step by Step scenario:
1.Go to Administration / System Initialization / Print preferences and select the tab per document.
2.Select the document stock transfer and tick the box print document when adding document and click on update.
3.Go to stock management / stock transactions / stock transfer
set the Crystal report template as default.
Note:
- The issue is reproduced also for Goods Receipt and Good Issue.
- The issue is reporduced with any Crystal Report Template for the above documents.
Cause
Program error
Solution
This issue is candidate for a change in a future release of SAP Business One.
Workarounds:
1.Use PLD for printing the stock transactions.
2.Convert the PLD layout to Crystal reports with Crystal converter.
3.Print the document after adding it.
Other terms
sap business one, printing issues, good issue, good receipt, stock transfer, crystal report, print preferences, print when adding, dockey, missing parameter
Header Data
Released on 07.02.2011 13:27:30
Release status Released for Customer
Component SBO-REP-CR Crystal Reports 2008 for SAP Business One
Other Components
SBO-GEN-PRT Printing Issues
Priority Correction with low priority
Category Program error
Validity
Software Component
Version
SAP BUSINESS ONE
8.8
8.81
you can download the PLD to Crystal Converter [here|http://www.sdn.sap.com/irj/scn/downloads?rid=/library/uuid/108305a7-1555-2d10-8289-9a178d441c71]
regards,
Fidel -
Call Function in Background Task
Hi all,
I have written a method in which I call a function in background task, I would like to perform a task after the function has ended succesfully. this is possible with the addition PERFORMING 'next_task' ON END OF TASK.
This is sadly not possible in a global class.
How can I get info back on the state of the function in the background?
greetings Fred.Hi,
try using export import statement in FM
call function ...
flay = 'Y'.
export flag to memory id 'TESt'
endfunction
import flag from memory id 'TEST'.
if flag = 'Y'.
perform next_task.
endif.
Regards
amole -
Call function in background task... How to get the result?
I want to use Call function in background task parameter.
But I cannot find the result of this function. (No export parameter, no table result, no exception)
How to get the result of this function module? Correct or not?Hi Heinz,
You can check the result in SM58 transaction.
For more information pls. refer this thread :
No IMPORTING parameters allowed in CALL FUNCTION IN BACKGROUND TASK
Best regards,
Prashant -
Save Order - Call function in background Task
Hi all,
I have written a function module which is called in order save Badi and copies the system status on the Master contract to the sub contracts.
This works fine but when I call this function in background task the status is not getting copied over.For testing I have created a program similar to function module and scheduled that in background and this was working as required.
Can someone please let me know if I missed out anything or how can i resolve this issue.
Any inputs in this regard would be very helpful.
Thanks and regards,
VijayHi Heinz,
You can check the result in SM58 transaction.
For more information pls. refer this thread :
No IMPORTING parameters allowed in CALL FUNCTION IN BACKGROUND TASK
Best regards,
Prashant -
Facing issue with tRFC (CALL FUNCTION in BACKGROUND TASK DESTINATION
In transcation CJ20N there is aBADI call ZCL_IM_CL_IM_PROJ_UPDATE in which there is a method
IF_EX_PROJECTDEF_UPDATE~AT_SAVE. My requirement is that when the status of the project is changed and saved then after the SAVE some actions are to be performed (BDC for transcation CJ30 & CJ9FS are to be called).
Since this method is called AT SAVE and i need to call the bdc after the comit (of SAVE) is done. So I have made a RFC FM in which I am calling the bdc. and then calling the FM as
CALL FUNCTION <FM> in BACKGROUND TASK DESTINATION <sy-sysid>.
For the txn. CJ9FS bdc this method is working fine and bdc is called after SAVE but for txn. CJ30, at times,the bdc is not working though if I run the BDC FM seperately using SE37 then its working fine.
Can any body guide me where I am going wrong.The scenario works fine for me. The issue was unable to create a proper test condition in the RFC.
CALL FUNCTION 'ZMY_RFCASYNC'
IN BACKGROUND TASK
EXPORTING...
TABLES...
EXCEPTIONS...
Simulated error condition in 'ZMY_RFCASYNC'
and got entry in SM58 by simply making an exception.
Thank you all. -
Help with bash function(set background=dark/light in vimrc)
I couldn't find any gvimrc files so I guess it uses the regular one. And since I work pretty much in X too I thought it would be nice with a function that sets background=light if I'm in X an background=dark if not. Is that possible?
/Richardvimrc configuration is not the same as bash.
You probably want something like this in your ~/.vimrc:
if has('gui_running')
set background=light
else
set background = dark
endif -
"Missing parameter values." Error when setting record selection formula
Setup - VS 2008, CR 2008 (v12.0), Win XP & C#.Net
I have a form which loops through all parameters (non-linked to sub reports, so only off the main report) and allows users to enter the values for each parameter. When hitting the preview button, I loop through all of the saved values, set the parameter field values and then add any additional filters into the recordselection formula as below. The problem i'm having is that the ReportDocument.HasRecords returns true if the ReportDocument.RecordSelectionFormula doesn't filter out every result.
For example, I have a list of customers and if I set the selection formula to filter out a specific customer, ReportDocument.HasRecors returns true, if I set the selection formula to filter something that doesn't exist i.e. customer "xk39df", the moment this line of code runs "ReportDocument.RecordSelectionFormula = rsFormula;" - ReportDocument.HasRecors returns the following exception as opposed to "False".
Message: Missing parameter values.
Source: CrystalDecisions.ReportAppServer.DataSetConversion
StackTrace: at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.hasRecords()
at CrystalDecisions.CrystalReports.Engine.ReportDocument.get_HasRecords()
ErrorID: MissingParameterFieldCurrentValue
The strange thing is, it works fine if the recordselectionformula selects a record which exists in the results - all parameters have a current value except for the linked parameters.
This one has got me stumped!
foreach (ParameterFieldDefinition parameterField in ReportDocument.DataDefinition.ParameterFields)
var query = ReportObjects.Values.Cast<Filters>().Where(objects => objects.ParameterName == parameterField.Name.ToUpper().Trim());
foreach (var item in query)
parameterField.CurrentValues.Clear();
parameterField.CurrentValues.Add(item.ParameterValue);
parameterField.ApplyMinMaxValues(item.MinLength, item.MaxLengh);
parameterField.ApplyCurrentValues(parameterField.CurrentValues);
var records = ReportObjects.Values.Cast<Filters>().Where(recordSelection => recordSelection.RecordSelectionFormula.Trim().Length != 0);
foreach (var item in records)
rsFormula += item.RecordSelectionFormula;
if (rsFormula.EndsWith(" AND "))
rsFormula = rsFormula.RTrim(5);
ReportDocument.RecordSelectionFormula = rsFormula;Hi,
The report has it's own ADO Datasource set in crystal reports, so I just pass the log on information to the report object before doing anything else.
this.DataSourceConnections[0].SetConnection("ServerName", "Database", "sa", "Password");
I then do a refresh before applying the parameter values (I do this because the user can preview the report more than one time by using a preview button on the parameter form without re-loading the report object)
this.Refresh();
Then I set all parameter values followed by setting the recordselection formula. -
User WF_BATCH dumps with TIME_OUT for a background task
Hello,
Situation :
While executing a workflow with a task defined as background task, the workflow creates a dump in ST22 after around 40 minutes. dump is because of TIME_OUT exception. And the workflow stays in status InProcess forever.
Question:
In my opinion background tasks do not have a time limit because they are executed as backgound batch jobs with batch user WF_BATCH. Then why do I get a TIME_OUT error ?
Is my assumption that workflow background task are just handled like other background jobs (sm36) is wrong ?
More Details :
I have a workflow with a task defined as background task (Task -> Basic Data -> Execution -> Check box 'Background processing' selected).
This task calls a method defined as 'Synchronous' method.
This method calls a ABAP FM having a select statement which selects large volume of Data.
If I execute this FM in Dialog mode definately I get a TIME_OUT. I understand this.
But what I do not understand is , while executing in background I do not expect TIME_OUT error since background jobs do not have a time limit. They can even run for several days.
Please let me know in what cases does a background job throws a time_out exception.esp wrt workflow.
Thanks in Advance
ShivanandCheck this link.
http://mailman.mit.edu/pipermail/sap-wug/2003-April/008883.html
Thanks
Arghadip -
Background location updates with the help of background task in ios
Hi,
we are building a navigation application, that updates location in background. The application receives location updates while in background by using CLLocation manager delegates. In order to reduce battery usage we take updates only on regular intervals say 5 min. For this are using NSTimer to fire an event that starts location update, fetch location and stop location updates for next 5 mins. This approach works well in foreground. But once the application is background this fails. When application fetches the location and stops the location updates for first time, the app gets suspended and never fires event to start location manger for subsequent times.
The solution we found, for keeping the timer alive is to track it using a background task. This way even if the location updates are stopped for a particular interval the application stays live to keep the timer running. My question is, is this method, a good approach for timed location updates in background states. Is this approach in any way prone to app store rejection as the 'background tasks' are designed to serve other specific scenarios.
Please share your thoughts on theseBill & stephen,
Not much help I'm afraid, but I just saw your post & wanted to let you know that I have the same problem, but for me it manifests itself in many apps. The only thing I've noticed is that it only seems to happen when I first start typing after not using the keyboard for a while (I'm not sure how long a while is, but maybe 30 seconds or so). Then I'll type & the first few letters will be fine, and then one letter double-types, and then it's fine again until I stop using it for whatever the threshold amount of time is. I'm guessing that it has something to do with the iPad's battery management & that it's shutting off the connection to the keyboard or something & once it picks it back up, then it double-types that letter.
At least in Pages, it isn't as big of a deal because I know it's coming, I can correct it & then type for a long time. In Numbers, my keyboard use is much less consistent, so I need to be more cognisant of it. -
CALL FUNCTION IN BACKGROUND TASK - enable tRFC
Hi Experts,
I want to call a Remote Function module 'IN bACKGROUND TASK' and get the status in SM58 within the same AS. Kindly help me to do this.
Requirement is to call the remote function module asynchronously in a guarentied way.
Thank you
NikhilThe scenario works fine for me. The issue was unable to create a proper test condition in the RFC.
CALL FUNCTION 'ZMY_RFCASYNC'
IN BACKGROUND TASK
EXPORTING...
TABLES...
EXCEPTIONS...
Simulated error condition in 'ZMY_RFCASYNC'
and got entry in SM58 by simply making an exception.
Thank you all.
Maybe you are looking for
-
How to Link column header only in classic Report in APEX 4.1
Hello Everybody, Probably there is a simpler way to do this, but I am not sure. I want a link on column header in Report on a specific column. The link will take me to new region or a page. How to achieve this in APEX 4.1 Theme : Blue 2 Database 11g
-
IBM 240X with Unmountable_Boot_Volume
The laptop turned off after a sudden power failure. After reboot, the error of unmountable_boot_volume displayed. Without a floppy drive, is there any method to resolve it?
-
No connection after installing firmware 1.10.03 on brand new Zen Nano P
Hi all, After I installed the new firmware, .0.03, my Zen Nano Plus is no longer recognised by my computer (it seems to work fine otherwise). What should I do? I have tried this on not just one, but three different computers, with no luck, even thoug
-
USB device (Logitech QuickCam Messenger) stopped working (SOLVED)
Hey there, I have a logitech quickcam messenger, which used to work perfectly 2 days ago. I updated my system yesterday and this morning, but I tried the cam again only now, and neither cheese nor webcamstudio work anymore (it never worked in skype s
-
Using AppleTV as an Airport Base Station?
Can I connect the ATV using ethernet and then use the AirPort part to extend the range of my WiFi network? I'd like that, because my house is made from thick reinforced concrete and WiFi signals have a hard time getting through. Connected like this,