V_QUERY_BBDW_CONSTITUENT_INTERACTION
Fields
| Field | Field Type | Null | Description |
|---|---|---|---|
| CONSTITUENTDIMID | int | yes | |
| INTERACTIONFACTID | int | ||
| INTERACTIONSYSTEMID | uniqueidentifier | yes | |
| FUNDRAISERCONSTITUENTDIMID | int | yes | |
| INTERACTIONDATEDIMID | int | yes | |
| INTERACTIONDATE | datetime | yes | |
| INTERACTIONOBJECTIVE | nvarchar(100) | yes | |
| INTERACTIONSUMMARY | nvarchar(100) | yes | |
| INTERACTIONCOMMENT | nvarchar(4000) | yes | |
| ISFIRSTINTERACTION | bit | yes | |
| ISLASTINTERACTION | bit | yes | |
| ACTUALDATEDIMID | int | yes | |
| ACTUALDATE | datetime | yes | |
| EXPECTEDDATEDIMID | int | yes | |
| EXPECTEDDATE | datetime | yes | |
| INTERACTIONCATEGORY | nvarchar(100) | yes | |
| INTERACTIONSTATUS | nvarchar(50) | yes | |
| INTERACTIONSUBCATEGORY | nvarchar(100) | yes | |
| CONTACTMETHOD | nvarchar(100) | yes |
Definition
Copy
create view BBDW.[V_QUERY_BBDW_CONSTITUENT_INTERACTION] as
select
i.[CONSTITUENTDIMID],
i.[INTERACTIONFACTID],
i.[INTERACTIONSYSTEMID],
i.[FUNDRAISERCONSTITUENTDIMID],
i.[INTERACTIONDATEDIMID],
i.[INTERACTIONDATE],
i.[INTERACTIONOBJECTIVE],
i.[INTERACTIONOBJECTIVE] [INTERACTIONSUMMARY],
i.[INTERACTIONCOMMENT],
i.[ISFIRSTINTERACTION],
i.[ISLASTINTERACTION],
i.[ACTUALDATEDIMID],
i.[ACTUALDATE],
i.[EXPECTEDDATEDIMID],
i.[EXPECTEDDATE],
di.[INTERACTIONCATEGORY],
di.[INTERACTIONSTATUS],
di.[INTERACTIONSUBCATEGORY],
di.[INTERACTIONTYPE] as [CONTACTMETHOD]
from BBDW.[FACT_INTERACTION] i
left join BBDW.[DIM_INTERACTION] di on i.[INTERACTIONDIMID] = di.[INTERACTIONDIMID] and i.[INTERACTIONDIMID] <> 0