Helpful upgrade tools
Use the following helpful tools to assist with iMIS upgrades.
Throughout the upgrade process, there may be many instances where you need to find queries that reference a specific business object. This script is meant to assist you when necessary and is not a script that you are required to run prior to upgrading.
See Finding queries that use a specific business object for details.
There may be instances where you need to list panel definitions and the related sources. The ListPanelDefinitionSources.sql script generates one row for every source included in a panel. If a panel is defined with two sources, the script will produce two rows for the panel, with each row corresponding to one of the sources.
Use this script with either an iMIS 2017 or EMS database.
-- Get entity sources
WITH XMLNAMESPACES(DEFAULT 'http://schemas.imis.com/2008/01/SharedDataContracts', 'http://schemas.microsoft.com/2003/10/Serialization/Arrays' AS a),
PanelXml AS (
SELECT [PanelDefinitionId],
[Name] AS PanelName,
[Description] AS PanelDescription,
[RelatedEntityName],
CAST([SerializedPanelDefinition] AS xml) AS [PanelDefinitionXml]
FROM [dbo].[PanelDefinition]
), PanelSources AS (
SELECT [PanelDefinitionId], [PanelName], [PanelDescription],
CAST(c.query('./text()') AS sysname) AS Source
FROM PanelXml x
CROSS APPLY [PanelDefinitionXml].nodes('/*/SelectedEntityNames/*') AS t(c)
)
SELECT *
FROM PanelSources