Sap Me Archiving How To Guide en
Sap Me Archiving How To Guide en
How-To Guide
Oracle is a registered trademark of Oracle Corporation. SAP shall not be liable for damages of any kind including
without limitation direct, special, indirect, or consequential
UNIX, X/Open, OSF/1, and Motif are registered trademarks of
damages that may result from the use of these materials.
the Open Group.
SAP does not warrant the accuracy or completeness of the
Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame,
information, text, graphics, links or other items contained within
VideoFrame, and MultiWin are trademarks or registered
these materials. SAP has no control over the information that
trademarks of Citrix Systems, Inc.
you may access through the use of hot links contained in these
HTML, XML, XHTML and W3C are trademarks or registered
materials and does not endorse your use of third party web pages
trademarks of W3C®, World Wide Web Consortium,
nor provide any warranty whatsoever relating to third party web
Massachusetts Institute of Technology.
pages.
Java is a registered trademark of Sun Microsystems, Inc.
SAP ME “How-to” Guides are intended to simplify the product
JavaScript is a registered trademark of Sun Microsystems, Inc., implementation. While specific product features and procedures
used under license for technology invented and implemented by typically are explained in a practical business context, it is not
Netscape. implied that those features and procedures are the only approach
MaxDB is a trademark of MySQL AB, Sweden. in solving a specific business problem using SAP ME. Should
SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP you wish to receive additional information, clarification or
NetWeaver, and other SAP products and services mentioned support, please refer to SAP Consulting.
herein as well as their respective logos are trademarks or
registered trademarks of SAP SE in Germany and in several
i
SAP ME How-To-Guide for Archiving
Document History
Document Version Description Author
1.0 Initial version Chet Moutrie
2.0 Updating to include Message Log Archiving and RTL and CTL Charlie Cutler
(Time Based Components (TBCT) Archive)
3.0 Updated to clarify background processing Netweaver parameter John Cohenour
and miscellaneous updates.
3.1 Updated to clarify Manual Archive Activity (DM530) relating to John Cohenour
SFC status.
3.2 Updated to add diagram for SAP HANA and explanation of warm Lauren Vaughn
storage for archive and audit log tables.
3.3 The following sections were updated: Sergiy Katerinich
• Archiving Overview: Time-Based Component
Traceability
• Archiving Overview: Business Purposes / Functions
• Archiving Functions: Manually Archive SFC or Shop
Order: Description and Applicability,
• Archiving Functions: Automatically Archive SFCs,
Shop Orders and Message Logs
• Archiving Setup: Archiving Setup Overview
• Maintenance Activities: System Setup Parameters
ii
SAP ME How-To-Guide for Archiving
Table of Contents
1 Introduction .......................................................................................................................................... 1
1.1 Purpose ............................................................................................................................................... 1
1.2 Scope................................................................................................................................................... 1
1.3 Glossary............................................................................................................................................... 1
2 Archiving Overview .................................................................................................................................... 2
2.1 Description and Applicability .............................................................................................................. 2
2.2 Business Purposes / Functions............................................................................................................ 5
2.3 High-Level Process Flows .................................................................................................................... 6
2.4 Best Practices ...................................................................................................................................... 6
3 Archiving Functions ................................................................................................................................... 6
3.1 Manually Archive SFC or Shop Order .................................................................................................. 6
3.1.1 Description and Applicability ....................................................................................................... 7
3.1.2 Potential Problems ...................................................................................................................... 8
3.2 Automatically Archive SFCs, Shop Orders and Message Logs ............................................................ 8
3.2.1 Description and Applicability ....................................................................................................... 8
3.2.2 Guidelines for Scheduling Archiving .......................................................................................... 10
3.2.3 Potential Problems .................................................................................................................... 11
3.3 Restore (Un-archive) SFCs or Shop Orders ....................................................................................... 11
3.3.1 Description and Applicability ..................................................................................................... 11
3.3.2 Best Practices............................................................................................................................. 11
3.4 Running Archiving Following Long Period without Archiving ........................................................... 11
4 Integration ............................................................................................................................................... 12
5 Archiving Setup ........................................................................................................................................ 12
5.1 Archiving Setup Overview ................................................................................................................. 12
5.1.1 Background Process Execution .................................................................................................. 13
5.1.2 Executing Automatic Archiving from Command Line ................................................................ 13
5.1.3 How Data is Batched.................................................................................................................. 14
iii
SAP ME How-To-Guide for Archiving
iv
SAP ME How-To-Guide for Archiving
1 Introduction
1.1 Purpose
The ME How-To-Guide for Archiving is intended to provide sufficient information to enable the
user to easily utilize the SAP ME Archiving feature, making use of available best practices. This
is applicable to ME 15.1 and 15.0.3.
Setting up archiving is an important step that should be addressed during initial ME system setup.
1.2 Scope
This information covers all aspects of the SAP ME Archiving feature. It does not cover in detail
the use of the ODS database ODS tables for holding detail and summary history data removed
from the WIP database. For more information regarding the ODS tables, see the SAP ME How
To-Guide – ODS Setup.
The ODS database contains ODS tables (used primarily for external reporting), Audit Log tables
(used for logging and viewing changes made to the SAP ME master data) and the Archive tables
(used to hold information regarding SFCs removed from the WIP database). This How-To-Guide
is focused primarily on the use of the Archive tables.
1.3 Glossary
Archive tables The tables in the ODS database that hold data, related to specific SFCs
and shop orders, that has been removed from the WIP database
Audit Log tables The tables in the ODS database that hold the history of changes to the
ME master data made via maintenance activities
ODS Operational Data Store
ODS database The ME database that consists of Audit Log tables, ODS tables and
Archive tables
ODS tables The ME operational data store tables that hold production history details
and summary history data for reporting and query purposes
WIP Work In Process
WIP database The ME transactional database that holds the current data regarding the
manufacturing execution objects and processes and the ME system
status.
RTL Resource Time Log
CTL Component Time Log
Message Board Messaging POD in ME, used to send messages about important system
information or Free Form Messages to Group of users.
1
SAP ME How-To-Guide for Archiving
Message Log
Tables The tables in the ODS database that hold the history of changes to the
ME Messages
2 Archiving Overview
This overview will provide a high level description of the configuration and use of the SAP ME
Archiving feature.
During real-time transactions, SAP ME stores data in the WIP (Work In Process) database tables.
These tables are designed and indexed to optimize data management for the real time functions of
SAP ME. Production data can be periodically transferred to the ODS tables and summarized in
the ODS summary tables. These tables are designed and indexed to optimize their use in the
creation and running of reports. WIP data modified via the ME maintenance activities can be
stored in the Audit Log tables of the ODS database. The ME Archive function stores SFC, Shop
Order, Time Based Component and Message Log related data in the Archive tables of the ODS
database.
The following figure illustrates and example of the high-level data landscape for SAP ME.
2
SAP ME How-To-Guide for Archiving
WIP Database ODS Database Global ODS Database
Audit Log Tables
Configuration Configuration
Data tables Audit
Changes
Archiving Tables
Transaction
Data Tables Archived SFC
Archive
Data
(Logging)
3
SAP ME How-To-Guide for Archiving
The following figure illustrates an example of the high-level data landscape for SAP ME on SAP
HANA. Additional WIP tables can be created in warm storage or the in-memory SAP HANA
database. The ODS module does not exist on the SAP HANA system.
WIP Database Additional WIP Tables
Audit Log Tables
Configuration Configuration
Data tables Audit
Changes
Production
Data Tables
Archiving Tables
Transaction
Data Tables Archived SFC
Archive
( Logging ) Data
Data can be periodically deleted from WIP tables via ODS scripts. This is only for WIP tables
that contain data that does not get archived to the Archive tables and that have corresponding
ODS tables. Data in the ODS tables can be periodically deleted via ODS scripts.
The Archiving feature moves records about a unique completed product (represented by an SFC
number) or about a shop order or about Closed, Revoked or Withdrawn Messages from the active
work in process (WIP) database to archive tables in the ODS database. Over a period of time, the
number of records in the WIP database becomes large. When the system has to search through a
very large number of records, it slows down the retrieval process. Archiving records, which are
no longer needed for production activities, can improve the retrieval speed of other production
records. Archiving moves SFC and/or shop order and Message Log related data from the WIP
database to the ODS database Archive tables.
To archive TBCT data the system moves the Resource Time Log, Resource Time Member,
Component Time Log records from WIP to ODS. Resource Time Member is an SFC-related data,
thus it is archived along with SFC records. Resource Time Log records are archived when they
have no child Resource Time Member records. Component Time Log records are archived when
they have no intersection with Resource Time Log records. All records are controlled by the
Days Before Archiving SFC/SO system rule.
4
SAP ME How-To-Guide for Archiving
In addition to the SFC objects and related child data, ME will archive the following types of SFC-
related objects:
• Closed engineering change order
• Shop order when the last SFC in the shop order is archived (automatic archiving only)
• Container when the last SFC of the container is archived
• SFC BOM when the last SFC using the BOM is archived
• Shop order BOM when the last SFC in the shop order is archived
• Closed RTL or CTL Records
Archiving can be applied to SFCs and shop orders with the following statuses:
• Done
• Closed
• Scrapped
• Deleted
• Invalid
Note: The Manual Archive activity, DM530, will archive an SFC or Shop Order regardless of the
status.
Archiving can be applied to Message Board messages with the following statuses:
• Closed
• Revoked
• Withdrawn Messages from the Message Log tables
Additionally, the system archives the following objects that are not directly related to SFCs:
5
SAP ME How-To-Guide for Archiving
• SFC-originated and purchased Inventory ID records
• ECO records
• Hold records
• Message Log records
• Resource and Work Center-related Parametric data records
• Downtime Notification records
• Resource Status Log records
During the archiving of an SFC, Shop Order or Message Logs, the system will process the child
records in a batch update for each archive table, to reduce the amount of time taken for archiving.
The system limits the number of records that can be batched together via the
archive.children.update.batch.size setting in the System Setup (SS500) activity.
3 Archiving Functions
3.1 Manually Archive SFC or Shop Order
The Archive (DM530) activity handles both manual archiving and restoring of SFCs and shop
orders. This section of the document covers only archiving.
NOTE: The manual archive does not archive the Message Log records.
6
SAP ME How-To-Guide for Archiving
3.1.1 Description and Applicability
Only one SFC or shop order can be selected at a time to be manually archived. To manually
archive an SFC or a shop order:
1. Select which type of object you want to archive (SFC or shop order)
2. Enter or browse and select the specific SFC or shop order
3. Select OK
The selected SFC or shop order typically should have one of the following status values
shown below. However, the manual archive activity will perform the archive regardless of
the status.
• Done
• Closed
• Scrapped
• Deleted
• Invalid
If a shop order is being archived, all SFCs for that shop order will be archived as well. The
following types of information and related ME objects, for the SFCs and shop order, will also
be archived:
• Activity Log entries
• Attachment records
• Container information
• Container instance (if the last SFC in the container is being archived)
• Data Collection information
• Document links
• Earned Standards information
• Engineering Change Order (ECO) information
• Engineering Change Order (if ECO is closed)
• Hold Log entries
• Incident numbers
• Inventory Log entries and information
• Nonconformance information
• Parametric (Data Collection) data
• Production Comments
• Routing information
• Sample plan information
• Sampling group information
• SFC assembly information
• SFC BOM (if the last SFC using the BOM is being archived)
• SFC Data
• SFC History
7
SAP ME How-To-Guide for Archiving
• SFC Router (if the last SFC using the Router is being archived)
• Shop Order BOM (only if the shop order is being archived)
• Shop Order inspection information (only if the shop order is being archived)
• Shop Order Routing (only if the shop order is being archived)
• Shop Order Subassembly information (only if the shop order is being archived)
• Tool Log entries
• Transfer data
• Time Sensitive Material information
• Work Instruction Log entries
• SFC-related Resource Time Member records
• Related Resource Time Log records if eligible
• Related Component Time Log records if eligible
Once the archive process has completed a success message will be displayed in the activity.
Automatic archiving will archive all shop orders that meet the following criteria:
• For the shop order, the number of days specified in the Days Before Archiving
SFC/SO system rule have elapsed
• The status of the shop order is one of the following:
• Done
• Closed
8
SAP ME How-To-Guide for Archiving
• Scrapped
• Deleted
• Invalid
The last SFC left in WIP, for the shop order, has been, or is being, archived.
The following types of information and related ME objects, for the SFCs and shop orders,
will also be archived:
• Activity Log entries
• Attachment records
• Container information
• Container instance (if the last SFC in the container is being archived)
• Data Collection information
• Document links
• Earned Standards information
• Engineering Change Order (ECO) information
• Engineering Change Order (if ECO is closed)
• Hold Log entries
• Incident numbers
• Inventory Log entries and information
• Nonconformance information
• Parametric (Data Collection) data
• Production Comments
• Routing information
• Sample plan information
• Sampling group information
• SFC assembly information
• SFC BOM (if the last SFC using the BOM is being archived)
• SFC Data
• SFC History
• SFC Router (if the last SFC using the Router is being archived)
• Shop Order BOM (only if the shop order is being archived)
• Shop Order inspection information (only if the shop order is being archived)
9
SAP ME How-To-Guide for Archiving
• Shop Order Router (only if the shop order is being archived)
• Shop Order Subassembly information (only if the shop order is being archived)
• Tool Log entries
• Transfer data
• Time Sensitive Material information
• Work Instruction Log entries
• SFC-related Resource Time Log records
• Related Resource Time Log records if eligible
• Related Component Time Log records if eligible
The selection of rows from the MESSAGE (WIP) tables will be based on the following criteria:
• The HANDLE is a match from the MESSAGE table.
• The MESSAGE table is queried for the handles that include a STATUS field of ‘C’
(Closed), ‘R’ (Revoked) or ‘W’ (Withdrawn).
• The MESSAGE table is queried for the handles that include a MODIFIED_DATE_TIME
that is less than the current GMT time minus the number of days to keep in WIP.
Additionally, the system archives the following objects that are not directly related to SFCs, based on the
status of the objects and the Days Before Archiving SFC/SO system rule:
10
SAP ME How-To-Guide for Archiving
3.2.3 Potential Problems
The following are problems that can occur during automatic archiving.
NOTE: Un-archive does not apply to Messages and the Message Log table information that has
been archived. That is, running the Un-archive process will not move Messages back to WIP.
Only SFCs and shop orders which are currently stored in the ODS database Archive tables
can be restored. If a shop order is selected to be restored, only that shop order will be
restored. If an SFC is selected to be restored, the SFC (and the owning shop order, if
archived) will be restored.
The types of information and related ME objects, for the SFCs and shop order which will be
restored, are the ones listed in section 3.1.1.
11
SAP ME How-To-Guide for Archiving
3. Reduce the value in the Days Before Archiving system rule by a small number of days
4. Run archiving
5. Repeat steps 3 and 4 until you have archived all of the data that needs to be archived at
this time
6. Schedule archiving to run periodically as needed, as described in Automatically Archive
SFCs and Shop Orders
4 Integration
Not Applicable
5 Archiving Setup
If a large number of SFCs or shop orders need to be archived at one time, or if materials have
very large BOMs, you may need to modify one or more of the following system setup
parameters:
• archive.children.update.batch.size
• archive.GUI.timeout
• archive.handle.expansion.fetch.size
• archive.handle.expansion.update.batch.size
• archive.timeout
• archive.max.rows
• archive.thread.count
12
SAP ME How-To-Guide for Archiving
Note: The Background Processing is enabled within Netweaver by setting a parameter. Refer
to the SAP ME Installation Guide for details on setting this parameter. It is important to have
this parameter set.
Select the checkbox in the Enabled column to turn on automatic archiving via background
process execution. The following table provides information regarding the other settings. Time
of day is specified using a 24 hour clock (e.g. 1:00 PM is entered as 13:00)
Run Every Setting After (Or Interval) Automatic archiving will be started
Every x Minutes Interval in minutes Every x minutes, starting immediately upon Save
Hourly Not used At the top of the hour (n:00) each hour of each day
Daily Start time (24 hour clock) At the specified time every day
Weekly - <day> Start time (24 hour clock) At the specified time, on the selected day, every week
13
SAP ME How-To-Guide for Archiving
You can also set up a scheduler to run the archive command line file periodically, at the time
interval appropriate for your site. Command Line processing invokes the archive for RTL and
CTL Archive as well as the Message Log Archive.
14
SAP ME How-To-Guide for Archiving
Setting Description
True Automatic archiving only archives components when the parent assembly is
archived, instead of when the component's status is Done. Change this setting,
in the Material Maintenance (PD060) activity system rules, to override other
archiving rules for materials that you want to keep in floor stock.
False (default) Automatic archiving archives components when their status is Done. This
setting results in fewer records in the WIP database at a given time. By the
time components are consumed out of finished goods inventory into a top
level assembly, their WIP records may have already been archived.
Note: The default value is 365 days. However, it is recommended to set this value as low
as reasonably possible to ensure adequate system performance.
15
SAP ME How-To-Guide for Archiving
reporting. The settings and description for this system rule are specified in the following
table. The global value can be overridden at the Site level.
Setting Description
True ME stores archived handles in an expanded format for easy reporting
False (default) ME stores archived handles in their usual concatenated format
We recommend leaving the system setup parameters at their default values unless you find a need
to change them.
5.3.2.1 archive.children.update.batch.size
This system setup property is the batch size used for moving child records while
archiving. It specifies the maximum number of child records that will be moved from
WIP tables to the corresponding ODS Archive tables in a batch update. The default is
100 records.
5.3.2.2 archive.GUI.timeout
This system setup property is the timeout value, in minutes, for the manual archiving
process. The default is 30 minutes.
5.3.2.3 archive.handle.expansion.fetch.size
This system setup property is the fetch size used when retrieving records to expand
handle columns in the Archive tables. The default is 50 records.
5.3.2.4 archive.handle.expansion.update.batch.size
This system setup property is the batch size used for updating records when expanding
the handles into separate columns in the Archive tables. The default is 20 records.
5.3.2.5 archive.timeout
This system setup property is the timeout value, in minutes, for the automatic archiving
process. The default is 30 minutes.
5.3.2.6 archive.max.rows
This system setup property is the number of parent records of each type (SFC, Shop
Order) that can be selected for an archiving execution (per site, per query selection). The
default is 10000 records.
5.3.2.7 archive.thread.count
This system setup property is the number of archiving threads that can be executed
simultaneously. The default is 16 threads.
16
SAP ME How-To-Guide for Archiving
17