Team Memberships History
This table has 1 row of per user - team membership with start and end date per org id.
Column | Type | Definition | Sample Value(s) | Sample Use |
---|---|---|---|---|
BENTO | Varchar | A collection of machines that power the Outreach app. Orgs live inside these. | This may distinguish orgs that are in different data centers. | |
CREATED_AT | Timestamp_NTZ | The UTC datetime that the user-team membership was created in Outreach. | ||
CREATOR_ID | Varchar | The creator user id of team-user pair in history. Maps to the USERS table | ||
DML_AT | Timestamp_NTZ | A datetime (local to server) in which the row was last modified. dml_at can be used to identify updated and new records, but as tables may not see changed records every day, it is not authoritative on when the table was last synced. | 2019-01-01 12:14:01:10 | Where dml_at::date >= current_date-7 This will return all rows modified in the last 7 days. |
DML_TYPE | Varchar | The type of manipulation that last occurred to a row. | 'update', 'delete', 'insert', 'backfill', 'backfill-delete' | Where dml_type <> 'delete' Excludes deleted rows. |
ID | Varchar | Represents an individual row of data in a table. Fields in other tables that match to this ID will be called thisTable_id. e.g. ID in the calls table will appear as the call_id in another table. | Count(1), count(id), and count(id) are equivalent in a table without joins or groupings for a given bento & o_id. | |
IS_DELETED_IN_APP | Boolean | Flag to indicate whether the user is still in the team, if it's true then the user left the team on the updated_at timestamp | Can be used in conjunction with updated_at timestamp to determine the end date of user's team membership | |
O_ID | Varchar | Organization ID, also called instance ID. This is the ID for your unique Outreach account. | Most commonly used on joins alongside other primary keys. where a.o_id = b.o_id and a.id = b.a_id | |
TEAM_ID | Varchar | The team id of team-user pair in history. Maps to the TEAMS table. | ||
SURROGATE_ID | Varchar | An md5 hash of bento, o_id and ID for a table. | ||
UPDATED_AT | Timestamp_NTZ | The UTC datetime that the user-team membership was last updated in Outreach. | ||
USER_ID | Varchar | The user id of team-user pair in history. Maps to the USERS table. |