2010 Mar 11 9:45 AM
Hi All,
I need to get all vendors (FK02) that were changed for the specified day and save it in a CSV file. I'm using version 4.6c and the problem is, there is no update date field in LFA1 or LFB1.
Is there a way to get the newly updated data?
Thanks,
Arlis
Hi All,
I need to get all vendors (FK02) that were changed for the specified day and save it in a CSV file. I'm using version 4.6c and the problem is, there is no update date field in LFA1 or LFB1.
Is there a way to get the newly updated data?
Thanks,
Arlis
2010 Mar 11 10:29 AM
Hi,
You can access field changes i.e. in FK03, follow: menu Environment -> Account changes -> All fields
If you debug this process (I set break point on SELECT statement), you will get select on CDHDR table).
You can check what select conditions are passed to this select and find manually, which vendors were modified.
Sample select is i.e. in form SELECT_CDHDR in include LSCD2F01.
Regards,
--
Przemysław
2010 Mar 11 11:10 AM
Hi,
All the changes in FK02 will be logged into CDHDR and CDPOS table. So you can read the table using below function modules to find what all the changes made during the period.
CDPOS has table name as field using that you can find the OBJECT CLASS
>CALL FUNCTION 'CHANGEDOCUMENT_READ_HEADERS'
>04.EXPORTING
>05.ARCHIVE_HANDLE = 0
>06.DATE_OF_CHANGE = '00000000'
>07.OBJECTCLASS = 'YTEST_TABLE_CNG'
>08.OBJECTID = ' '
>09.TIME_OF_CHANGE = '000000'
>10.USERNAME = SY-UNAME
>11.LOCAL_TIME = ' '
>12.DATE_UNTIL = '99991231'
>13.TIME_UNTIL = '235959'
>14.NOPLUS_ASWILDCARD_INOBJID = ' '
>15.TABLES
>16.I_CDHDR = GT_CDHDR
>17.EXCEPTIONS
>18.NO_POSITION_FOUND = 1
>19.WRONG_ACCESS_TO_ARCHIVE = 2
>20.TIME_ZONE_CONVERSION_ERROR = 3
>21.OTHERS = 4.
>22.IF SY-SUBRC <> 0.
>23.MESSAGE 'No entries found' TYPE 'E'.
>24.ENDIF.
>26.IF NOT GT_CDHDR IS INITIAL.
>28.LOOP AT GT_CDHDR INTO GS_CDHDR.
>30.CALL FUNCTION 'CHANGEDOCUMENT_READ_POSITIONS'
>31.EXPORTING
>32.CHANGENUMBER = GS_CDHDR-CHANGENR
>33.TABLES
>34.EDITPOS = GT_CDSHW
>35.EDITPOS_WITH_HEADER = GT_CDRED
>36.EXCEPTIONS
>37.NO_POSITION_FOUND = 1
>38.WRONG_ACCESS_TO_ARCHIVE = 2
>39.OTHERS = 3.
>40.IF SY-SUBRC <> 0.
>41.MESSAGE 'No item details found' TYPE 'E'.
>42.ELSE.
2010 Mar 12 3:36 AM
Hi All,
Thanks for the suggestions. I've found the user exit that I could use for this problem.
I used EXIT_SAPMF02K_001.
Thanks.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |