on 06-23-2007 3:27 PM
Hi Experts,
I am using RFC called Cats_Read_Catsdb_Input. In this RFC, the input parameter is Personal No. For one personal number, there will be lot of records. I have done the programming correctly. However the output is not getting displayed. I suspect that there is some issue with Cardinality and Selection. Can you please let me know what will be the setting of Cardinality and Selection if one input parameter returns many output records.
Regards,
SG
Hi SG,
According to the context structure
Bapi_Employee_Getdata_Input
|--- Output
| -
Personal_Data(under Output node )
|--- Employee_Id
Here is the code.
1>Take a method say GetEmployeeDetailsByNo inside component controller with parameter empid of type string.
Use this implementation.
public void GetEmployeeDetailsByNo( java.lang.String empid )
{
//@@begin GetEmployeeDetailsByNo()
IWDMessageManager msg = wdComponentAPI.getMessageManager();
try {
Bapi_Employee_Getdata_Input input = new Bapi_Employee_Getdata_Input();
input.setEmployee_Id(empid);
wdContext.nodeBapi_Employee_Getdata_Input().bind(input);
wdContext.currentBapi_Employee_Getdata_InputElement().modelObject().execute();
wdContext.nodePersonal_Data().invalidate();
} catch (Exception e) {
// TODO Auto-generated catch block
msg.reportSuccess(e.getMessage());
e.printStackTrace();
}
//@@end
}
2> Now go to the view and bind the Model node (Bapi_Employee_Getdata_Input
) in the view layout.
And inside on action event of Searchbutton uses this code.
public void onActionGoEmpSearch(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
{
//@@begin onActionGoEmpSearch(ServerEvent)
wdThis.wdGetEmployeeCompController().GetEmployeeDetailsByNo(wdContext.currentBapi_Employee_Getdata_InputElement().getEmployee_Id());
//@@end
}
public void wdDoInit()
{
//@@begin wdDoInit()
Bapi_Employee_Getdata_Input bapiInput = new Bapi_Employee_Getdata_Input();
wdContext.nodeBapi_Employee_Getdata_Input().bind(bapiInput);
//@@end
}
Check the code you may get some hints.If you get any specific error post it.
Regards,
Mithu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello SG
No need to set Cardinality and Selection for RFC output nodes.
Is it giving any error? Can you more details.
<b>One more Just make sure that you are checjing RFC output node</b>.
Just print LogMessage with Table UI element you come to know what is the exact error.
Rgds
-SS
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
the node which gets the output must be of the cardinality 0..n. Input node 1..1
Regards,
Sharadha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.