Extending Analytics for LS Central
Chapter 4 - Staging 6
Add new affix
If you want to extend Analytics with staging tables from an extension that you have added to your LS
Central instance, you need to start by adding the affix to the LSInsight$PublisherAffixReg table.
You can add to the LSInsight$PublisherAffixReg table using the Add or Delete App Affix pipeline
in the Analytics ADF.
When you add the trigger for the pipeline you are prompted with several fields:
• AppID (extension GUID from LS Central table)
• AppName (name of installed extension)
• Publisher (name of publisher of Extension)
• Prefix (the three-letter prefix used, if used. Not required)
• Suffix (the three-letter suffix used, if used. Not required)
These are the fields you need to populate to add a record to the table.
In addition, there is the DeleteApp field that decides whether a record is added or deleted from the
table. It is set to FALSE by default, but if it is changed to TRUE it deletes a matching record from the
table. When deleting, all you need to do is enter the Extension GUID in the AppID field and change the
DeleteApp value to TRUE. You can only add or delete one App record at a time.
Add to prestaging tables – LS Central SaaS only
Update existing prestaging table
Analytics already includes prestaging table creation scripts for all BC, LS Central and LS Central for
Hotel tables used in Analytics.
If you have an extension that extends one of those tables you will need to add the columns from the
extension to the appropriate prestaging tables. The prestaing tables are exactly the same as the LS
Central tables so if you need to add columns from a new extension you need to add them to the table
prefixed with $ext and include the column prefix and GUID suffix. Make sure that the column is of the
same data type as in the LS Central database. You can add a new columun by creating an alter table
script.
The format of such a script would look like this:
ALTER TABLE [dbo].[<Company>$<TableName>$<BaseTableGUID>$ext]
ADD [<Prefix> <Column Name>$<Extension GUID>] <datatype> NULL
If we for example had an extension with prefix = ITR and GUID = 383d7016-f0b9-4296-8de3-
cbd429b7b066 that added a column called ‘Activity Type’ to the LSC Trans_ Sales Entry table the
script would look like this:
ALTER TABLE [dbo].[My Company$LSC Trans_ Sales Entry$5ecfc871-5d82-43f1-9c54-59685e82318d$ext]
ADD [ITR Activity Type$383d7016-f0b9-4296-8de3-cbd429b7b066] NVARCHAR(20) NULL
Add new prestaging table
If you are running Analytics against LS Central SaaS, you need to add the new prestaging tables
manually to the Analytics database.