We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fff32e3 commit 2969876Copy full SHA for 2969876
1 file changed
SQL Queries/ReportServer/Reporting_Datasource.sql
@@ -1,4 +1,27 @@
1
-SELECT Name,
2
- Link,
3
- ItemID
4
-FROM [ReportServer].[dbo].[DataSource]
+SELECT
+ U.UserName AS Creator_Username,
+ C2.Name AS Data_Source_Name,
+ C.Name AS Dependent_Item_Name,
5
+ C.Path AS Dependent_Item_Path
6
+FROM
7
+ ReportServer.dbo.DataSource AS DS
8
+ INNER JOIN
9
+ ReportServer.dbo.Catalog AS C
10
+ ON
11
+ DS.ItemID = C.ItemID
12
+ AND
13
+ DS.Link IN (SELECT ItemID FROM ReportServer.dbo.Catalog
14
+ WHERE Type = 5) -- Type 5 identifies data sources
15
+ FULL OUTER JOIN
16
+ ReportServer.dbo.Catalog C2
17
18
+ DS.Link = C2.ItemID
19
+ LEFT JOIN
20
+ ReportServer.dbo.Users AS U
21
22
+ C.CreatedByID = U.UserID
23
+WHERE
24
+ C2.Type = 5
25
+ORDER BY
26
+ C2.Name ASC,
27
+ C.Name ASC;
0 commit comments