# Workflow Process Instance The `workflowprocessinstance` table is part of the [MySQL database schema](https://docs.workflowengine.io/database-schema/mysql/) used by Workflow Engine. The `workflowprocessinstance` table stores the current state and execution metadata for process instances. This page lists the table columns in database order together with types, nullability, primary keys, defaults, and indexes. ## Table columns The `workflowprocessinstance` table contains 19 columns in database order. Data types and default expressions use the syntax defined by MySQL. Table: workflowprocessinstance columns | Position | Column | Database type | Nullable | Primary key | Default | |----------|--------|---------------|----------|-------------|---------| | 1 | `Id` | `binary(16)` | No | Yes | - | | 2 | `StateName` | `varchar(256)` | Yes | No | - | | 3 | `ActivityName` | `varchar(256)` | No | No | - | | 4 | `SchemeId` | `binary(16)` | No | No | - | | 5 | `PreviousState` | `varchar(256)` | Yes | No | - | | 6 | `PreviousStateForDirect` | `varchar(256)` | Yes | No | - | | 7 | `PreviousStateForReverse` | `varchar(256)` | Yes | No | - | | 8 | `PreviousActivity` | `varchar(256)` | Yes | No | - | | 9 | `PreviousActivityForDirect` | `varchar(256)` | Yes | No | - | | 10 | `PreviousActivityForReverse` | `varchar(256)` | Yes | No | - | | 11 | `IsDeterminingParametersChanged` | `bit(1)` | Yes | No | - | | 12 | `ParentProcessId` | `binary(16)` | Yes | No | - | | 13 | `RootProcessId` | `binary(16)` | No | No | - | | 14 | `TenantId` | `varchar(128)` | Yes | No | - | | 15 | `StartingTransition` | `longtext` | Yes | No | - | | 16 | `SubprocessName` | `longtext` | Yes | No | - | | 17 | `CreationDate` | `datetime` | No | No | `CURRENT_TIMESTAMP` | | 18 | `LastTransitionDate` | `datetime` | Yes | No | - | | 19 | `CalendarName` | `varchar(256)` | Yes | No | - | ## Database indexes The `workflowprocessinstance` table defines 4 database indexes. Definitions retain the column or field order and sort direction used by the database. Table: workflowprocessinstance indexes | Index | Unique | Definition | |-------|--------|------------| | `PRIMARY` | Yes | ``Id`` | | `SchemeId` | No | ``SchemeId`` | | `ix_calendarname` | No | ``CalendarName`` | | `ix_workflowprocessinstance_rootprocessid` | No | ``RootProcessId`` |