Skip to main content
Kofax

MarkView Advisor - Schema Cleardown / Re-synchronization Instructions

Summary 

4839

Applies To

  • ERP System : Oracle, SAP
  • MarkView Version: 6.2 to 9.0

Behavior

  • In certain scenarios the data in the Advisor Schema may need to be cleared down in order to re- sychronize the data between the ERP System and MarkView Advisor.

Resolution

In order to prevent the issue from occurring ensure that Cold-Sync completes successfully before starting the Hot-Sync Process. If this issue does occur the following steps can be taken to cleardown the Advisor Schema.

Please Note that this process will remove all of the data from the MarkView Advisor Schema. Once the Advisor Schema has been cleared down the Cold-Sync process will need to be executed in order to populate Advisor with the initial data load.
  • Stop the MarkView Application Server Processes
  • ERP Specific Instructions
    • SAP
      • Have your SAP Basis team write an ABAP Script with the following lines:
        REPORT ZADVISOR_CLEARDOWN .
        
        DELETE FROM /S170/MVAM_TERMH WHERE CODE <> ''.
        
        DELETE FROM /S170/MVAM_TERMD WHERE CODE <> ''.
        
        DELETE FROM /S170/MVAM_INVDT WHERE OBJECT_KEY <> ''.
        
        DELETE FROM /S170/MVAM_BLOCK WHERE ZAHLS <> ''.
        
        DELETE FROM /S170/MVAM_INVHO WHERE OBJECT_KEY <> ''.
        
        DELETE FROM /S170/MVAM_ETDTL WHERE EVENT_ID <> ''.
        
        DELETE FROM /S170/MVAM_ETVAL WHERE EVENT_ID <> ''.
        
        COMMIT WORK.
      • There will be no results displayed when the script is executed. Therefore you should manually check the tables in SAP with Products.SapDataBrowser.
    • Oracle Applications
      • There are no ERP Specific Instructions which need to be taken.
  • Remove Data from the MarkView Schema
    • Delete all records in the mvam_* tables EXCEPT the MVAM_AP_USER_GROUP table. If you elect to use truncate rather than delete, you will need to temporarily disable constraints on table MVAM_EVENT_MESSAGE_SYNC_DETAIL. Before truncating this table, issue the following command:
      • alter table MVAM_EVENT_MESSAGE_SYNC_DETAIL disable constraint MVAM_EMD_EVENT_MESSAGE_ID_FK;
      • Once the table is truncated you can then re-enable the constraint:
        alter table MVAM_EVENT_MESSAGE_SYNC_DETAIL enable constraint MVAM_EMD_EVENT_MESSAGE_ID_FK;
    • Delete all records in the MV_ADVISOR_HOTSYNC_Q_TAB and MV_ADVISOR_RLTIME_Q_TAB tables. (These may be empty already.)
    • MarkView 7.0.2/7.1.1 and higher delete all records in the MV_ADVISOR_HS_Q_TAB and MV_ADVISOR_RT_Q_TAB tables. (These may be empty already.)
  • Remove Data from the Advisor Schema ( Note that the referenced scripts are located within the cold-sync-cleanup.zip file attached to this Article. )
    • MarkView versions 6.3 and below run the cold-sync-cleanup2.sql script
    • MarkView version 6.4 run the cold-sync-cleanup3.sql script
    • MarkView version 6.5 run the cold-sync-cleanup4.sql script
    • MarkView versions 7.0 and and higher run the cold-sync-cleanup5.sql script
  • Restart the MarkView Application Server Processes
  • At this point the Advisor data has been cleared down. You can now perform a Cold-Sync Export and Cold-Sync Import against this environment. (You must take a new Cold-Sync Export in order to ensure you have the current data before performing the Import. )

Related Component

For general MarkView Advisor troubleshooting steps please review:

Keywords: schema, sync