Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Message type in BDCMSGCOLL Structure in Call transaction using BDCDATA

Former Member
0 Likes
2,254

Hi,

We are facing issue while capturing message in BDCMSGCOLL structure in Call transaction using bdcdata. The message which are like

Message 'Message Text' Type 'S' Display LIke 'E' .

This message is captured as Success on the Message structure instead of error & user are asking to update it as Error as it is looking like Error message to the end user.

Please provide resolution to the issue.

Regards,

Kapil

8 REPLIES 8
Read only

VenkatRamesh_V
Active Contributor
0 Likes
1,536

Hi Kapil,

Hope I understand, if not reply me.

If you are uploading many datas via BDC means,  you can append the messages to internal table,

After that you can display it with record data and its   corresponding message ?.

If your are uploading one data means you can display with Type 'E', other data's will not be processed ?.

Regards,

Venkat.

Read only

0 Likes
1,536

Hi Venkat,

I am not doing any upload, i am just doing a replay of the transaction ME21 & in that there are many error message which encounter while creating a PO but when i have check the logic , they are basically a success message which are display like Error so when i have called ME21 transaction using below statement

call transaction ME21 using BDCDATA

                                        into messages bdcmsgcoll.

I am getting the message as success only since the message are of type success but as they are display like E , so user want that in msgcoll structure these messages must be shown as Error.

Regards,

Kapil.

Read only

Former Member
0 Likes
1,536

Hi Kapil,

Since you already know the message ID and the number for that particular message, try checking for it in your result table for messages. If that exists, change it to 'E'.

LOOP AT msg_tab WHERE msgid = 'Your Msg ID'

AND msgnr = 'Msg No.'

*

msg_tab-msgtyp = 'E'.

MODIFY msg_tab.

*

ENDLOOP.

Read only

0 Likes
1,536

Hi sharmila,

Actualy , i don't want to hardcode the things , i want to know why message structure is showing the exact message type not how it is shown to the end user.

Also, can this behavior of the Message be change by passing some parameter in option or by passing some mode.

Regards,

Kapil.

Read only

0 Likes
1,536

Hi,

here is a similar (same) thread, this might help you.

http://scn.sap.com/thread/3396615

I do not see your code but if you have a look at the "helpful answer" in this thread it might be the case you are facing as well? So this part with the condition check...

Read only

0 Likes
1,536

Kapil,

The message structure will only have the actual message type. " DISPLAY LIKE 'E' " is only used for GUI display.

I don't think you could control this through options or mode in CALL TRANSACTION.

Read only

0 Likes
1,536

Hi,

you may consider to use function BAPI_PO_CREATE. Hereyou get a RETURN table with all messages reelvant for user.

And, I don't know SAP uses the DISPLAY LIKE technique in ME21(N). Is this from a user exit?

Regards

Clemens

Read only

0 Likes
1,536

Hi Clemens,

Agreed , i can use the bapi but there is a limitation to do it through BDC only.actually this is not just to upload the data but to replicate the user steps in frontend and track user messages which encounter while processing .

Standard SAP uses Display like E to display message line enter purchase req / Enter plant that i have checked that is the only reason why in BDCMSGCOLL structure showing all message as Success .

Regards,

Kapil.