> ## Documentation Index
> Fetch the complete documentation index at: https://docs.superoffice.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ticket_log table

> This table contains log entries for the tickets.

## ticket\_log Table (267)

This table contains log entries for the tickets.

## Fields

| Name              | Description                                                   | Type                      | Nullable |
| ----------------- | ------------------------------------------------------------- | ------------------------- | :------: |
| id                | The primary key (auto-incremented)                            | PK                        |    No    |
| ticket\_id        | The id of the ticket this entry is connected to.              | FK [ticket](./ticket.mdx) |    No    |
| log\_code         | An enum indicating what kind of log-entry this is.            | log\_code                 |    Yes   |
| log\_who          | The username/alias of the user performing the action.         | String(255)               |    Yes   |
| log\_when         | When the action occured.                                      | DateTime                  |    Yes   |
| log\_description  | A string describing the event (or part of such) to be logged. | Clob                      |    Yes   |
| log\_what\_value2 | A reference to various tables, depending on the log\_code.    | Int                       |    Yes   |

<img src="https://mintcdn.com/superofficeas/8-OIGQQJR0VGDXy_/media/loc/en/database/tables/ticket_log.png?fit=max&auto=format&n=8-OIGQQJR0VGDXy_&q=85&s=b6c636bdc657aaf014f49e9061d46ca7" alt="ticket_log table relationship diagram" width="360" height="59" data-path="media/loc/en/database/tables/ticket_log.png" />

## Indexes

| Fields            | Types    | Description |
| ----------------- | -------- | ----------- |
| ticket\_id        | FK       | Index       |
| log\_code         | Enum     | Index       |
| log\_when         | DateTime | Index       |
| log\_what\_value2 | Int      | Index       |

## Relationships

| Table              | Description                                                                              |
| ------------------ | ---------------------------------------------------------------------------------------- |
| [ticket](./ticket) | This table contains the tickets (requests) of the system. Its purpose should be evident. |

## Replication Flags

* None

## Security Flags

* No access control via user's Role.


## Related topics

- [ticket_log_change table](/en/database/tables/ticket-log-change.md)
- [ticket_log_action table](/en/database/tables/ticket-log-action.md)
- [Enum values for TicketLogAction](/en/database/tables/enums/ticketlogaction.md)
- [Enum TicketLogAction](/en/automation/crmscript/reference/CRMScript.NetServer.TicketLogAction.md)
- [Enum TicketLogFieldChange](/en/automation/crmscript/reference/CRMScript.NetServer.TicketLogFieldChange.md)
- [ticket table](/en/database/tables/ticket.md)
