Skip to main content
The PersonWorkspace entity represents the relationship between a person and a workspace in the Well system. It serves as a Many-to-Many linking table and enables sharing people between different workspaces while maintaining workspace isolation.

Table structure

Table name: person_workspaces

Main fields

NameTypeRequiredConstraintsAllowed ValuesDescriptionExample
idstring, UUID, πŸ”’ systemβœ… YesUnique identifier (read-only)–Unique identifier of the person-workspace relationship”person-workspace-uuid-123”
personPeople (UUID)βœ… YesForeign key reference–Reference to the person”person-uuid-456”
workspaceWorkspace (UUID)βœ… YesForeign key reference–Reference to the workspace”workspace-uuid-789”
created_atstring (ISO 8601) πŸ”’ system–auto timestamp–Creation timestamp”2023-01-01T12:00:00Z”
updated_atstring (ISO 8601) πŸ”’ system–auto timestamp–Last updated timestamp”2024-01-01T12:00:00Z”
deleted_atstring | null πŸ”’ systemβšͺ Nonullable ISO 8601–Deletion timestamp (soft delete)β€œ2024-01-01T12:00:00Z”

Relations

Many-to-One relations

  • People: The person in the relationship
  • Workspace: The workspace in the relationship

Relationship schema

PersonWorkspace (N) ←→ (1) People
PersonWorkspace (N) ←→ (1) Workspace

# Enables Many-to-Many relationship:
People (N) ←→ (N) Workspace via PersonWorkspace
⌘I