# Towards a Domain-Specific Modeling Language for Extracting Event Logs from ERP Systems
## 1 Introduction  
At present, organizations use enterprise resource planning (ERP) systems as a core information and communications technologies (ICT) component. ERP systems encompass configurable modules supporting business processes that have received wide industrial adoption, and they contain extensive amounts of data about the behaviors of such processes. Recorded data can be used to analyze whether a predefined process specification conforms with real activities [1]. Process mining offers automated techniques for this type of analysis. Process mining has emerged in the past few years as a new analytical discipline that focuses on extracting insights about processes from the event data stored in information systems. Process mining provides the techniques to automatically discover process models from data, find the mismatch between process models and process executions, and improve models based on information obtained from their past executions [2]. These techniques rely on the existence of an event log whose structure is suitable for mining. An event log assumes that events that refer to an activity occur at a particular time in precisely one case [3]. While event logs structured in this form are mostly available in process-aware information systems, such a structure is not explicitly generated by ERP systems and other domain-specific business systems [4, 5, 6]. These systems record events implicitly, separately, and without a common case identifier. Thus, such logs need to be generated from the data that typically exist in a relational database. To build such an event log is the key enabler for process mining and is a complex task [7, 8]. To extract data from ERP systems in an event log format suitable for process mining, several challenges need to be addressed. First, there is not one possible case notion, butmultiple case notions (called object types) which could be used to correlate the corresponding events in traces [9]. For example, a purchase order or purchase invoice document can be identified as a case notion for a purchasing process in an ERP system. Second, data are organized in documents related to each other through one-to-many and many-to-many relationships, and activities are often related to these documents. Due to the data featuring one-to-many and many-to-many relations, an activity can be performed multiple times on a single document or performed only once but on different documents; however, existing process mining techniques and tools require an XES event log as an input. The eXensible Event Stream (XES) format [10] is the current Institute of Electrical and Electronics Engineers (IEEE) standard for storing events and requires a single case notion to correlate events and precisely one case per event. Thus, the resulting log may suffer from convergence (one event is related to multiple cases) and divergence (multiple events of the same type are related to one case) when extracting an event log from the ERP system, as described in [11]. This may lead to duplicated events and false data dependencies between events. This paper emphasizes the challenge of building an event log from ERP systems supporting domain knowledge. Extracting events from an ERP database requires substantial domain knowledge of the business processes and underlying data model [2]. Data constraints in ERP systems are generally managed at the application level [12; 13]. In this situation, when data relations are defined outside a database schema, domain knowledge is essential to select the correct data from database tables. The semantics of event data and where they are stored within an ERP system is known by domain experts. [PERSON] and [PERSON] [14] specified a set of decisions that domain experts often need to make when creating event logs from databases. They have discussed how these decisions can affect log quality. One of these decisions is the selection of a meaningful case notion.