cancel
Showing results for 
Search instead for 
Did you mean: 

message type

Former Member
0 Kudos

hi friends,

why we need Message Type ,though its same as DataType?pls help on this.

urs

ravi

Accepted Solutions (0)

Answers (3)

Answers (3)

aashish_sinha
Active Contributor
0 Kudos

Hi,

A message type comprises a data type that describes the structure of a message.

Activities

1. Create a message type on the design maintenance screen of the Integration Builder (see also: Creating a New Object).

2. Enter a description for your message type.

3. The default setting for XML Namespace is the Repository namespace. If the message type has been copied to another namespace, overwrite the default setting.

4. Reference a data type, either by entering the corresponding name and namespace of the data type in the frame Data Type, or by using the input help.

5. Save your changes.

Refer http://help.sap.com/saphelp_nw04/helpdata/en/2d/c0633c3a892251e10000000a114084/content.htm for more details.

Hope this will help you.

Regards

Aashish Sinha

PS : reward points if helpful

Former Member
0 Kudos

HI,

Message Type:

A message type comprises a data type that describes the structure of a message. At the following points in SAP Exchange Infrastructure you can refer to the message to be exchanged at runtime by using the message type:

· More than one message interface can use the same message type. For example, an asynchronous outbound message interface and an asynchronous inbound message interface can reference the same message type because the request message does not need to be mapped.

· When defining a message mapping you can directly reference message types to map messages from an outbound interface to messages from a receiver interface.

For technical reasons, a data type is not sufficient to describe the instance of a message. In XML schema, data types are defined as abstract types that are not yet fixed to an element. You can only describe an instance of a message when you have specified a data type as an element type. Therefore, a message type defines the root element of a message.

A message type does not define the direction of the message exchange, in other words, whether it is a request or a response. In exceptional cases you can use the same message type for both the request and the response message.

Features

A message type has the following characteristics:

· It comprises exactly one data type, which determines the content of the message to be transferred.

· It is identified by a name and an XML namespace. The name (together with the namespace) of a message type is located in the uppermost tag of the message to be exchanged. This is an element tag.

You have defined a message type GreetingRes that references a simple data type of type xsd:string. The XML namespace of the message type is http://sap.com/xi/myExample. The corresponding payload might look like this:

<?xml version="1.0" encoding="utf-8" ?>

<ns1:GreetingRes xmlns:ns1="http://sap.com/xi/myExample"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

Hello Mrs. Miller

</ns1:GreetingRes>

Refer the below help:

http://help.sap.com/saphelp_nw04/helpdata/en/2d/c0633c3a892251e10000000a114084/frameset.htm

Thnx

Chirag

Former Member
0 Kudos

Hi ravi,

for mappings (JAVA, XSLT ..) you need a ROOT-element. A datatype does not have a ROOT-Element.

And: By having a hierarchie (Datatype --> Message-Type) you can use a datatype in different message-types with different names. This is sometimes usefull.

regards Mario