Change to DSW that needs to be documented
Reason: wanted to use a Data Source Registry entry that qualified as a Migration data source (sdb) but pointed to a dsw database (dswCentral)
Options: change code below or add dsw to the allowable zSourceDatabaseFilter
Result: changed the code
In DB Console in webDataSource_SourceDataSourceList
The code originally
SELECT DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceID, DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceName, DSPCommon.dbo.apiCranSoftDataSourceSel.[Database], '' AS Type
FROM Console.dbo.ztParam AS ztParam CROSS JOIN
DSPCommon.dbo.apiCranSoftDataSourceSel
WHERE (DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceID IN
(SELECT DataSourceID
FROM DSPCommon.dbo.apiCranSoftDataSourceSel AS apiCranSoftDataSourceSel_1
WHERE (ServerAddress IN
(SELECT ServerAddress
FROM DSPCommon.dbo.apiCranSoftDataSourceSel AS DataSource_1
WHERE (DataSourceID = 'F704C419-2A8F-4C92-AFD4-AD75EA7B9C93'))))) AND (DSPCommon.dbo.apiCranSoftDataSourceSel.[Database] LIKE ztParam.zSourceDatabaseFilter)
UNION
SELECT [SourceID], [Source], '', 'Natural' AS Type
FROM [Console].[dbo].[ttSource]
WHERE SourceType IN (5, 6)
Was changed to
SELECT DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceID, DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceName, DSPCommon.dbo.apiCranSoftDataSourceSel.[Database], '' AS Type
FROM Console.dbo.ztParam AS ztParam CROSS JOIN
DSPCommon.dbo.apiCranSoftDataSourceSel
WHERE (DSPCommon.dbo.apiCranSoftDataSourceSel.DataSourceID IN
(SELECT DataSourceID
FROM DSPCommon.dbo.apiCranSoftDataSourceSel AS apiCranSoftDataSourceSel_1
WHERE (ServerAddress IN
(SELECT ServerAddress
FROM DSPCommon.dbo.apiCranSoftDataSourceSel AS DataSource_1
WHERE (DataSourceID = 'F704C419-2A8F-4C92-AFD4-AD75EA7B9C93'))))) AND (DSPCommon.dbo.apiCranSoftDataSourceSel.[DataSourceName] LIKE ztParam.zSourceDatabaseFilter)
UNION
SELECT [SourceID], [Source], '', 'Natural' AS Type
FROM [Console].[dbo].[ttSource]
WHERE SourceType IN (5, 6)
Hello Megan, I will look into this further as I see the benefit. My only reservation is if there is code out that that assumes that the data source and database names are the same and therefore uses the datasource name to get the database name.
Attachments Open full size