> ## 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.

# AssociateHistory table

> Historical information about associates that have been deleted. Most references are NOT declared as foreign keys; this is a historical table that should not be updated when further changes occur in the database

## AssociateHistory Table (539)

Historical information about associates that have been deleted. Most references are NOT declared as foreign keys; this is a historical table that should not be updated when further changes occur in the database

## Fields

| Name                      | Description                                                   | Type                                            | Nullable |
| ------------------------- | ------------------------------------------------------------- | ----------------------------------------------- | :------: |
| associatehistory\_id      | Primary key                                                   | PK                                              |    No    |
| associateId               | The original primary key of the deleted associate             | Int                                             |    Yes   |
| groupId                   | The group id                                                  | Int                                             |    Yes   |
| personId                  | The person id                                                 | Int                                             |    Yes   |
| type                      | Associate type                                                | Enum [AssociateType](./enums/associatetype.mdx) |    Yes   |
| originalRegistered        | Registered when                                               | UtcDateTime                                     |    Yes   |
| locationAddress           | Address of location, if this is a resource that is a location | String(239)                                     |    Yes   |
| ejUserId                  | The ejuser reference, if any                                  | Int                                             |    Yes   |
| name                      | The associate name/initials                                   | String(255)                                     |    Yes   |
| firstname                 | First name                                                    | String(99)                                      |    Yes   |
| middleName                | Middle name or 'van' etc.                                     | String(99)                                      |    Yes   |
| lastname                  | Last name                                                     | String(99)                                      |    Yes   |
| contactId                 | The original contact\_id                                      | Int                                             |    Yes   |
| registered                | Registered when                                               | UtcDateTime                                     |    No    |
| registered\_associate\_id | Registered by whom                                            | FK [associate](./associate.mdx)                 |    No    |

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

## Indexes

| Fields | Types | Description |
| ------ | ----- | ----------- |

## Relationships

| Table                    | Description                                                        |
| ------------------------ | ------------------------------------------------------------------ |
| [associate](./associate) | Employees, resources and other users - except for External persons |

## Replication Flags

* None

## Security Flags

* No access control via user's Role.


## Related topics

- [Enum values for AssociateType](/en/database/tables/enums/associatetype.md)
- [History table](/en/database/tables/history.md)
- [History](/en/api/reference/restful/rest/sale/history.md)
- [navigation_history table](/en/database/tables/navigation-history.md)
- [Save Histories](/en/api/reference/restful/agent/viewstate_agent/save-histories.md)
- [Get History](/en/api/reference/restful/agent/viewstate_agent/get-history.md)
