on 08-04-2009 10:14 PM
If I model a structure in the ESR, using a name like dtXYZ, with attributes FirstName and LastName, why does SAP change the names to
DT_XYZ, FIRST_NAME, LAST_NAME when you look at them in the internal view of SPROXY? The external names are not changed.
They appear to be placing an underscore when the case changes when creating the data type proxy (via SPROXY) internal view.
Ideas?
Hi,
While you are creating proxy, several ABAP objects are created,
External view: is original view of service as it looks from outside.
Internal view: ABAP objects created by SOA framework of SAP.
Internal view is used by programmer for coding and framework is responsible between mapping external and internal view.
Why SAP generate its object: these objects are as per naming rules followed by SAP (limits on number of char, size etc) and there are no rule how they should be generated (i.e underscore etc).
There could be conflict as well with other objects thats why SAP ask to provide prefix so that conflict with other objects can be avoided.
As a programmer/Service developer we are only interested in ABAP objects or internal view, rest is taken care by SOA framework of SAP.
Regards,
Gourav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I completely agree with adding of the prefix for internal objects. What I am questioning is why they chose to change the name based on the case of the structure.
Try it - create a data type in the ESR using the values I supplied. Then go in SPROXY in your provider system and see how SAP changes the internal names.
If I define data type dtXYZ, then go in an implement the proxy with a prefix ZWS, then I get internal view object ZWSDT_XYZ. Why is the underscore added?
Hi,
Well you are right there is apparently no reason to change name. But not always xml names and xsd types are compatible with abap data type and abap field name rules (i.e. lenght of string).
I belive they change data type based on preset rule of verb, noun and adjective.
So if you give something like FirstName it become First_Name.
But if you give only Name it will remain Name (or NAME as it is not case sensitive in ABAP).
So if you give fieldname which doesn;t make any sense like "xyzswdroeks" they will not be able to break it. And only breaking of it will be after 4-5 chars.
But as I said before it is not a concern of ABAPer and outside world as nothing change for outside world and ABAPer will focus on internal view.
Regards,
Gourav
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.