Table

smmLeadRelTable

Lead relations table

Links leads to other records. The reference is stored as a table ID and a record ID. The metadata names projects, campaigns and opportunities as possible targets. The key is the reference plus the lead.

Table name
smmLeadRelTable
Module
Sales and marketing
Table group
Main
Table type
Regular
Data per company
Yes
Configuration key
SmmLead
Primary index
LeadRefIdx
Replacement key
LeadRefIdx
Key fields
RefRecId, RefTableId, LeadId
Model
Foundation

Fields (8)

Field and descriptionType / EDT / enumMandatoryReferencesIn public entities
RefRecIdSystem record ID of the record the lead is linked to.Int64
RefRecId
NoNone
RefTableIdID of the table that holds the linked record.Integer
RefTableId
NoNone
LeadIdID of the lead. Points to the lead record.String (20)
smmLeadId
YessmmLeadTable.LeadIdNone
DataAreaIdThe company (legal entity) that the record belongs to. System field.String (4)
DataAreaId
NoNone
PartitionA system field for the data partition. In most environments every record has the same value. System field.Int64
Partition
NoNone
RecIdA unique number that the system gives to every record. Other tables often use it to point to this record. System field.Int64
RecId
NoNone
RecVersionA system number that changes each time the record is updated. It is used to detect conflicting updates. System field.Integer
RecVersion
NoNone
TableIdA system number that identifies the table. System field.Integer
TableId
NoNone

Indexes (2)

Relations (4)

Each relation joins smmLeadRelTable to another table on the fields shown.

  • ProjTable → ProjTable

    Join on RefTableId = ProjTable.TableId, RefRecId = ProjTable.RecId

    Many smmLeadRelTable records → zero or one ProjTable record

  • smmCampaignTable → smmCampaignTable

    Join on RefRecId = smmCampaignTable.RecId, RefTableId = smmCampaignTable.TableId

    Many smmLeadRelTable records → zero or one smmCampaignTable record

  • smmLeadTable → smmLeadTable

    Join on LeadId = smmLeadTable.LeadId

    Many smmLeadRelTable records → exactly one smmLeadTable record

  • smmOpportunityTable → smmOpportunityTable

    Join on RefTableId = smmOpportunityTable.TableId, RefRecId = smmOpportunityTable.RecId

    Many smmLeadRelTable records → zero or one smmOpportunityTable record

Get this data out

No public entity reads from smmLeadRelTable. Its data is only reachable through the application, a custom entity or a database export.

Need help with smmLeadRelTable in a report, an integration or a migration? Talk to Dr Dynamics.

Email sales@drdynamics.co.uk