in bdc program i am getting message output for all screen , where as i want only success and failure message ..
bdc recording for mm01
my code is \
CALL TRANSACTION 'MM01'
USING bdcdata
MODE bmode
MESSAGES INTO messtab .
CLEAR bdcdata.
REFRESH bdcdata.
CLEAR: IT_FINAL,g_msg.
LOOP AT messtab.
CLEAR: g_msg.
CALL FUNCTION 'FORMAT_MESSAGE'
EXPORTING
ID = messtab-msgid
LANG = messtab-msgspra
NO = messtab-msgnr
V1 = messtab-msgv1
V2 = messtab-msgv2
V3 = messtab-msgv3
V4 = messtab-msgv4
IMPORTING
MSG = g_msg
EXCEPTIONS
NOT_FOUND = 1
OTHERS = 2.
WRITE:/ G_MSG.
ENDLOOP.
CLEAR: messtab,G_MSG.
REFRESH:messtab.
ENDLOOP.