# Data model requirements

> A data model can only be saved when it adheres to the following requirements:

A data model can only be saved when it adheres to the following requirements:

* The data model includes no more than 40 tables.
* All tables are connected to the overall data model.
* There are no circular relations in the data model.
* A maximum of 15 direction changes are allowed in one relation path.
  :::tip
  A direction change is a one-to-many relation followed by a many-to-one relation, or vice versa.
  :::

  ![Direction changes explained](https://dev-assets.cms.uipath.com/assets/images/process-mining/process-mining-direction-changes-explained-371362-eed190a5-818aedb5.webp)

## Required output tables

A data model must have a `Cases`, `Event_log`, `Tags`, and `Due_dates` table.

:::note
Depending on the app template, the `Cases` table has a process-specific name, for example, `Purchase_order_items`, or `Incidents`.
:::

The `Cases`, `Event_log`, `Tags`, and `Due_dates` table must have the following output fields.

:::note
All the fields are required. However, some fields are allowed to contain only NULL values.
:::

| **Table** | **Required output field** |
| --- | --- |
| `Cases` | `Case_ID`* |
| `Event_log` | `Case_ID`* |
|  | `Event_start` |
|  | `Event_end` |
|  | `Activity` |
|  | `Activity_order` |
|  | `Automated` |
|  | `Event_cost` |
|  | `Event_processing_time` |
| `Tags` | `Tag_ID` |
|  | `Case_ID`* |
|  | `Tag` |
|  | `Tag_type` |
| `Due_dates` | `Case_ID`* |
|  | `Due_date` |
|  | `Due_date_type` |
|  | `Actual_date` |
|  | `Expected_date` |
|  | `On_time` |
|  | `Cost` |
|  | `Difference` |

*) Depending on the app template, `Case_ID` can be called differently, for example, `Purchase_order_item_ID`, or `Incident_ID`.
