on 2005 Aug 03 10:07 AM
Hi all,
Please, anyone with experience in both ABAP and WD Adaptive RFC, enlighten me regarding the following:
1. Input parameters for ABAP RFC function may have default value assigned. What values / expressions may be used here? From what I can found it is:
- constants ('character' or numeric)
- predefined data object SPACE + SY structure fields (SY-UNAME)
- Anything else???
2. I'm just wondering how SY-fields are applied by RFC client. Is there any way to get SY structure at client side? Simple "don't assign values" solution seems not to work... Or it is Adaptive RFC model specific...
3. Also it is unclear to me how user-specific SY-fields are working when user mapping involved for creating JCo connection.
Thanks in advance,
VS
Ok,
There is no silver bullet to solve this issue.
So my own solution was a custom implementation at client-side with the following rules (see http://help.sap.com/saphelp_46c/helpdata/en/7b/fb96c8882811d295a90000e8353423/content.htm#aktuellesS...
1. Certain category of SYST fields may be implemented as on-demand functions (Information About the Current R/3 System, Information About the Current Terminal Session, formation About Current Date and Time) with JCo.Connection, currently logged-in user and current session locale information.
2. Other are constants (plus SPACE built-in here)
3. The rest just have no sense for remote RFC (loops, string operation, screen & printing functions)
4. If it is not "SY-*" or "SPACE" then this is constant, where string is quoted like 'CONST', numbers are numbers in radix 10, and boolean true is 'X'
5. Haven't chance to try date / time / timestamp constants (functions are trivial)
VS
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For question 1 also include
i)enumerations and
ii)field exits(methods attached to fields that converts data into internal format on assignment)
Regards
Pran
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your tip.
Sure, enumerations are the case, but it is applied in generated model classes transparently (or at least I get desired behavior without any coding from my side
Could you elaborate a bit about "field exits"? Probably you can point me to some function available in any ABAP installation?
VS
Hi
Field exits are coversion routines attached to the domain on which a particular field is based upon.These routines get activated only if the data is passed though SAP gui. For RFCs these routines are bypassed because of which the end user is sometimes presented with data that is an internal format . Examples of domains in SAP which has conversion routine.
PS_POSNR(Cost Center)
KOSTL (WBS Element)
An example of screen presentation
WBS Elements are represented internally in database as A00010001 but the same might be presented as A.00.01.001 for an end user on SAP screen , however since RFC calls bypass conversion routines this would be presented as A00010001 in a webdynpro screen.
Currently how we handle it is by having wrapper RFCs that use CHAR fields and the data is pre converted using the same routines and passed through the CHAR fields.
A java representation might be
public class Integer{
...
...
public String toString(){
/*could be any routine here */
return "0000"+i;
}
}
Eg for standard Funtion module CATS_READ_TIMESHEET_DATA
Regards
Pran
User | Count |
---|---|
73 | |
10 | |
8 | |
7 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.