Skip to Content
avatar image
Former Member

Changed Data not updating through TMG

Hi All,

I have a Z table in which I have added some events in its TMG.

My problem is the table is not getting updated while I change any record.

The event number is 18.

Please help.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

5 Answers

  • Best Answer
    avatar image
    Former Member
    Jan 08, 2015 at 10:50 AM

    Hi all,

    It is done.

    Solution is as below.

    In the Event 02 the code is written.

    DATA: W_ZDCC_REMARK TYPE ZDCC_REMARK. " DCC Document Reason for Remark

       FIELD-SYMBOLS: <FS1> TYPE ANY,
                      <FS2> TYPE ANY,
                      <FS3> TYPE ANY.

       CLEAR W_ZDCC_REMARK.

       ASSIGN ('<VIM_EXTRACT_STRUC>-REMARK') TO <FS1>.


       IF <FS1> IS ASSIGNED.
         SELECT SINGLE * FROM ZDCC_REMARK INTO W_ZDCC_REMARK
           WHERE REMARK = <FS1>.
           IF  sy-subrc = 0.
             W_ZDCC_REMARK-ZUNAME = SY-UNAME.
             W_ZDCC_REMARK-ZERSDA = SY-DATUM.
             W_ZDCC_REMARK-ZUZEIT = SY-UZEIT.
             MODIFY ZDCC_REMARK FROM W_ZDCC_REMARK.
           ENDIF.
       ENDIF. " IF <FS1> IS ASSIGNED


    One additional thing is also needed for the same.

    We have to configure the table in transaction SCDO.

    This will solve the purpose.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 07, 2015 at 01:00 PM

    Hi Yash,

    After creating event number 18, Create another event 02 for "after save".

    It will save the changes.

    Best Regards,

    Somya

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 07, 2015 at 02:36 PM

    You're going to have to share your code if you really want some help.

    Rob

    Add comment
    10|10000 characters needed characters exceeded

  • Jan 07, 2015 at 03:30 PM

    Hi Yash,

    Are you updating the Table primary key via TMG. Normally during change, when we are updating theĀ  Table primary key for the particular recordĀ  in that time only the TMG won't work. Kindly confirm the same.

    If you still face the problem, kindly share the code written in event and table screenshot too...

    Regards

    Rajkumar Narasimman

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 08, 2015 at 06:12 AM

    Hi Yash,

    Instead of doing it through event . you can achieve this through writing

    code in overview sceen number PAI.

    TRY below code.

    IN PAI

       FIELD ZDCC_REMARK-ZUNAME module custom_pai.

    FIELD ZDCC_REMARK-ZERSDA module custom_pai.

    FIELD ZDCC_REMARK-ZUZEITmodule custom_pai.

    MODULE   custom_pai input.

    ZDCC_REMARK-ZUNAME = sy-uname.
    ZDCC_REMARK-ZERSDA = SY-DATUM.
    ZDCC_REMARK-ZUZEIT = Sy-UZEIT.

    ENDMODULE.


    Thanks,

    Marimuthu.K

    Add comment
    10|10000 characters needed characters exceeded