Skip to main content
Version: Next

Data Sink Configuration

Data clients can be configured to receive extraction results (linkage map data) for specific data sources, or for all data from the server. For the latter, LinXmart must be configured to allow the data client to receive all of this data.

For a specific data source, the LinkageMapSink property defines the details of where extraction results are stored. For the general receive-all, a LinkageMapSink property can be defined at the same level as the DataSources property. Either way, the configuration settings are the same for both, but are located in different areas within the appsettings.json or appsettings.datasources.json files.

The properties of a data sink are described below:

PropertyDescription
TypeThe LinXmart Data Client supports one connection type for data sinks:
  • SQL Server (Microsoft SQL Server)
PropertiesThese are properties specific to the data source type:
  • ConnectionString - the full connection string to the data source in the format required by the Type
  • CredentialsName - (optional) if a username/password combination is required for the connection string, you can instead specify the name of the credentials stored in the service account user's credential store - it will add these to the connection string at runtime
  • Table - the name of the table to write data
  • AppendProjectCodeToTable - flag indicating if the table name should have the project code appended
  • CreateTableIfRequired - flag indicating if the table should be created if it doesn't exist
  • DeleteExisting - flag indicating if existing data for the extraction project and event type should be deleted before new data is written
ColumnMappingA mapping of linkage map properties to column names in the destination. The following mappings are mandatory:
  • ProjectCode
  • EventTypeCode
  • SourceUniqueId
  • PersonKey
The following are optional. If they are omitted from the appsettings.json configuration, they will be ignored:
  • SourcePersonId
  • ExtractionProjectId
  • LinkageProjectPersonKey
Additional linkage field columns can be added using the LinkageFields sub-property (see below)
info

PostgreSQL and ODBC are not currently supported as data sinks.

If you want to create a compatible table yourself, an example creation script for SQL Server for all standard fields are shown below.

CREATE TABLE [dbo].[LXM_Extraction_Results] (
[ProjectCode] [nvarchar](50) NULL,
[EventTypeCode] [nvarchar](50) NULL,
[SourceUniqueId] [nvarchar](100) NULL,
[SourcePersonId] [nvarchar](100) NULL,
[PersonKey] [nvarchar](100) NULL,
[ExtractionProjectId] [nvarchar](100) NULL,
[LinkedProjectPersonKey] [nvarchar](100) NULL
);

Additional linkage fields​

Linkage fields can be included in the linkage map extraction if required. For example, you may have another identifier that needs to be paired with the original record identifier and person key.

The ColumnMapping.LinkageFields property is an array of name-value pairs, identifying the linkage field name and the destination column name.

The following example shows a ColumnMapping entry that includes the linkage field, TextField1.

"ColumnMapping": {
"ProjectCode": "Project Code",
"EventTypeCode": "Event Type Code",
"SourceUniqueId": "Source Unique Id",
"SourcePersonId": "Source Person Id",
"PersonKey": "Person Key",
"ExtractionProjectId": "Extraction Project Id",
"LinkedProjectPersonKey": "Linked Project Person Key",
"LinkageFields": [
{
"Name": "TextField1",
"DestinationColumn": "Grouping"
}
]
}