Think I worked out the problem:
There is a trigger on the tabs table. I have no idea if its core dnn or was added by some dangerous module developer?
CREATE TRIGGER [dbo].[DNN360Menu_Update] ON [dbo].[Tabs]
FOR UPDATE
AS
DECLARE @PortalID int
SET @PortalID = (SELECT PortalID FROM Deleted)
Delete from dbo.MCISS_MenuUpdate where PortalID= @PortalID
Insert into dbo.MCISS_MenuUpdate (lastupdate,portalID) values (getdate(),@PortalID)
GO
I arrived at this conclusion because I modified the DNN upgrade script like this:
WITH RecursiveTabs (TabID, Level, TabPath)
AS
(
SELECT
TabID,
0 AS Level,
CAST('//' + dbo.RemoveStringCharacters(TabName, '&? ./''-#') AS NVARCHAR(255)) AS TabPath
FROM dbo.Tabs
WHERE ParentId IS Null
UNION ALL
SELECT
T.TabID,
R.Level + 1,
CAST(R.TabPath + '//' + dbo.RemoveStringCharacters(TabName, '&? ./''-#') AS NVARCHAR(255))
FROM dbo.Tabs T
INNER JOIN RecursiveTabs R ON T.ParentId = R.TabID
)
--UPDATE dbo.Tabs SET Level = R.LEVEL, TabPath = R.TabPath
--FROM dbo.Tabs T
--LEFT JOIN RecursiveTabs R ON R.TabID = T.tabID
select 'UPDATE dbo.Tabs SET Level =' + cast(R.Level as varchar) + ',' + 'Tabpath=' + '''' + R.Tabpath + '''' + 'where tabid=' + cast(T.TabID as varchar) from dbo.Tabs T
LEFT JOIN RecursiveTabs R ON R.TabID = T.tabID order by T.tabpath
This gave me a list of updates like this:
UPDATE dbo.Tabs SET Level =2,Tabpath='//MembersHome//ManageSite//NewsAnnouncements'where tabid=64
UPDATE dbo.Tabs SET Level =3,Tabpath='//MembersHome//ManageSite//DocumentManagement//DocumentTypePermissions'where tabid=65
UPDATE dbo.Tabs SET Level =3,Tabpath='//MembersHome//ManageSite//testarea//AccessLinkTestPage'where tabid=66
When I ran these I noticed that there were three notifications happening after a single update.
Does anyone know what if this trigger is a DNN thing or a third party thing?
I will try removing it before upgrade.
Gus