Easily find this page again using the shortlink: https://bct.azrcrv.co.uk/3901
Table Type: Company
Table Name: Retention Policy Setup
Database Table Name: CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f
Due to how Dynamics BC tables and columns are named, square brackets need to be wrapped around the table name and column names. Below are example queries showing how Retention Policy Setup can be queried.
Show/hide an example select of all columns
SELECT
*
FROM
[CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f]
Show/hide an example select of all columns by name
SELECT
[Table Id]
,[Retention Period]
,[Enabled]
,[Apply to all records]
,[Date Field No_]
,[Manual]
,[Number Of Records Deleted]
,[$systemId]
,[$systemCreatedAt]
,[$systemCreatedBy]
,[$systemModifiedAt]
,[$systemModifiedBy]
FROM
[CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f]
Show/hide an example select of all columns including those from all joined tables
SELECT
*
FROM
[CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Policy Setup]
LEFT JOIN
[CRONUS UK Ltd_$Data Exch_ Mapping$437dbf0e-84ff-417a-965d-ed2bb9650972] AS [Data Exch. Mapping]
ON
[Retention Policy Setup].[Table ID] = [Data Exch. Mapping].[Table ID]
LEFT JOIN
[CRONUS UK Ltd_$Retention Period$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Period]
ON
[Retention Policy Setup].[Retention Period] = [Retention Period].[Code]
LEFT JOIN
[User] AS [User]
ON
[Retention Policy Setup].[SystemCreatedBy] = [User].[User Security ID]
LEFT JOIN
[User] AS [User]
ON
[Retention Policy Setup].[SystemModifiedBy] = [User].[User Security ID]
Show/hide columns in Retention Policy Setup table
Field No. | Field Name | Field Caption | Class | Type | Length | SQL Column Name | SQL DataType |
---|---|---|---|---|---|---|---|
1 | Table Id | Table Id | Normal | Integer | 4 | Table Id | int |
Key to join to the Data Exch. Mapping table.Show/hide example querySELECT [Retention Policy Setup].[Table Id] ,[Data Exch. Mapping].[Table ID] FROM [CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Policy Setup] LEFT JOIN [CRONUS UK Ltd_$Data Exch_ Mapping$437dbf0e-84ff-417a-965d-ed2bb9650972] AS [Data Exch. Mapping] ON [Retention Policy Setup].[Table Id] = [Data Exch. Mapping].[Table ID] | |||||||
2 | Table Name | Table Name | FlowField | Text | 30 | ||
3 | Table Caption | Table Caption | FlowField | Text | 249 | ||
4 | Retention Period | Retention Period | Normal | Code | 20 | Retention Period | nvarchar(40) |
Key to join to the Retention Period table.Show/hide example querySELECT [Retention Policy Setup].[Retention Period] ,[Retention Period].[Code] FROM [CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Policy Setup] LEFT JOIN [CRONUS UK Ltd_$Retention Period$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Period] ON [Retention Policy Setup].[Retention Period] = [Retention Period].[Code] | |||||||
5 | Enabled | Enabled | Normal | Boolean | 4 | Enabled | tinyint |
6 | Apply to all records | Apply to all records | Normal | Boolean | 4 | Apply to all records | tinyint |
7 | Date Field No. | Date Field No. | Normal | Integer | 4 | Date Field No_ | int |
8 | Date Field Name | Date Field Name | FlowField | Text | 30 | ||
9 | Date Field Caption | Date Field Caption | FlowField | Text | 80 | ||
10 | Manual | Manual | Normal | Boolean | 4 | Manual | tinyint |
100 | Number Of Records Deleted | Number Of Records Deleted | Normal | Integer | 4 | Number Of Records Deleted | int |
2000000000 | $systemId | System ID | Normal | GUID | 16 | $systemId | uniqueidentifier |
2000000001 | SystemCreatedAt | Created At | Normal | DateTime | 8 | $systemCreatedAt | datetime |
2000000002 | SystemCreatedBy | Created By | Normal | GUID | 16 | $systemCreatedBy | uniqueidentifier |
Key to join to the User table.Show/hide example querySELECT [Retention Policy Setup].[$systemCreatedBy] ,[User].[User Security ID] FROM [CRONUS UK Ltd_$Retention Policy Setup$63ca2fa4-4f03-4f2b-a480-172fef340d3f] AS [Retention Policy Setup] LEFT JOIN [User] AS [User] ON [Retention Policy Setup].[$systemCreatedBy] = [User].[User Security ID] | |||||||
2000000003 | SystemModifiedAt | Modified At | Normal | DateTime | 8 | $systemModifiedAt | datetime |
2000000004 | SystemModifiedBy | Modified By | Normal | GUID | 16 | $systemModifiedBy | uniqueidentifier |