1. Yes it is running on SQL Server 2008 R22. Table DDL for table needing to be populated:SET ANSI_NULLS ONGOSET QUOTED_IDENTIFIER ONGOCREATE TABLE [dbo].[CUSTOMER_USAGE]( [Customer] [nvarchar](max) NOT NULL, [SHORTNAME] [nvarchar](max) NOT NULL, [AdGroup] [nvarchar](max) NULL, [DBASE] [nvarchar](max) NULL, [RM_Users] [nvarchar](max) NULL, [RO_Users] [nvarchar](max) NULL, [DM_Users] [nvarchar](max) NULL, [File Count] [nvarchar](max) NULL, [File Size] [nvarchar](max) NULL [DB Size] [nvarchar](max) NULL) ON [PRIMARY]GO
3. All of the databases are on the same server and instance of SQL Server 2008 R2. The databases and tables are all the same format, large tables (the DBs are part of an off the shelf content management system). The DDL's for these would be rather large but I can post if they will be helpful/needed.4. There aren't really any business rules, as they are all the same type of DB with the same type of content, the table has to be populated with the same data from each.If it helps at all, I will try to explain again also with example data:[Customer] contains the full name of our customer such as "WACO"[SHORTNAME] contains a shortned name that is used to identify the customers library in this case again "WACO"[AdGroup] Contains the ActiveDirectory master group for customers, not important to me.[DBASE] Contains the name for the DB in SQL Server 2008 R2 for that customers library, in this case again ECM_CM_WACO[RM_Users] This field needs to be populated with the results of a query, preferably referencing the SHORTNAME above and the database name from the DBASE column, but the query for my "WACO" customer would be:Select Count(*) as "Number of Users" from ECM_CM_WACO.ECM_CM_WACO.KUAF where id in (select childid from ECM_CM_WACO.ECM_CM.WACO.kuafchildren where id = (Select id from ECM_CM_WACO.ECM_CM.WACO.kuaf where name = 'WACO RM Users'))
[RO_Users] Same as above, needs to be populated from the query below, just changes the RM to RO:Select Count(*) as "Number of Users" from ECM_CM_WACO.ECM_CM_WACO.KUAF where id in (select childid from ECM_CM_WACO.ECM_CM.WACO.kuafchildren where id = (Select id from ECM_CM_WACO.ECM_CM.WACO.kuaf where name = 'WACO RO Users'))
[DM_Users] Same as above, needs to be populated from the query below, just changes the RO to DM:Select Count(*) as "Number of Users" from ECM_CM_WACO.ECM_CM_WACO.KUAF where id in (select childid from ECM_CM_WACO.ECM_CM.WACO.kuafchildren where id = (Select id from ECM_CM_WACO.ECM_CM.WACO.kuaf where name = 'WACO DM Users'))
[File Count] Needs to be populated, once again using the DBASE column to would be preferable but for my WACO customer it would be:select count(distinct docid) as "Number of Documents" from ECM_CM_WACO.dversdata[File Size] Same as above but filesize instead of file count:select sum((datasize)/1048576) as "Total Size(MB)" from ECM_CM_WACO.dversdata[DB Size] Needs to be populated to show the disk size of the database for that customer (ie in this case the ECM_CM_WACO database)Since I am an involuntary DBA (SA left after staff cuts) and am being pressured to make this happen by month end, I appreciate any and all help you can provide.