Symantec Management Platform (Notification Server)

 View Only
  • 1.  Report Issue

    Posted Feb 16, 2012 07:04 PM
      |   view attached

    Can someone please look at the attached report and see if you can figure out why my computer names are being duplicated multiple times?  It seems to be related to the container field.  Thanks!



  • 2.  RE: Report Issue

    Posted Feb 16, 2012 07:29 PM

    Can you post this as straight SQL?

    In general, you are probably getting multiple rows per computer because the rows are unique in some way.  Can you post the SQL?



  • 3.  RE: Report Issue

    Posted Feb 17, 2012 11:08 AM

    DECLARE @v1_var2 nvarchar(max)
       SET @v1_var2 = N'%var2%'
    DECLARE @v2_var1 nvarchar(max)
       SET @v2_var1 = N'%var1%'
    DECLARE @v3_TrusteeScope nvarchar(max)
       SET @v3_TrusteeScope = N'%TrusteeScope%'
    DECLARE @v4_var4 nvarchar(max)
       SET @v4_var4 = N'%var4%'
    DECLARE @v5_var3 nvarchar(max)
       SET @v5_var3 = N'%var3%'
    DECLARE @v6_CurrentContainer nvarchar(max)
       SET @v6_CurrentContainer = N'%CurrentContainer%'
    DECLARE @v7_BaseResourceType uniqueidentifier
       SET @v7_BaseResourceType = '%BaseResourceType%'
    SELECT
       [vri8_Resource].[Guid] AS [Guid],
       [vri8_Resource].[Name] AS [Name],
       [ajs9_ouMem].[Distinguished Name] AS [Container],
       [ajs10_Inv_OS_Operating_System].[Name] AS [OS Name],
       [ajs11_Inv_HW_Video_Controller_Windows].[Installed Display Drivers]
    FROM
       [vRM_Resource_Item] AS [vri8_Resource]
          INNER JOIN ([Inv_OU_Membership] AS [ajs9_ouMem]
             INNER JOIN [Inv_OS_Operating_System] AS [ajs10_Inv_OS_Operating_System]
                ON ([ajs9_ouMem].[_ResourceGuid] = [ajs10_Inv_OS_Operating_System].[_ResourceGuid])
             INNER JOIN [Inv_HW_Video_Controller_Windows] AS [ajs11_Inv_HW_Video_Controller_Windows]
                ON ([ajs9_ouMem].[_ResourceGuid] = [ajs11_Inv_HW_Video_Controller_Windows].[_ResourceGuid]))
             ON ([vri8_Resource].[Guid] = [ajs9_ouMem].[_ResourceGuid])
          INNER JOIN [ResourceType] AS [ajs12_rt]
             ON ([vri8_Resource].[ResourceTypeGuid] = [ajs12_rt].[Guid])
          INNER JOIN [ResourceTypeHierarchy] AS [ajs13_rth]
             ON ([vri8_Resource].[ResourceTypeGuid] = [ajs13_rth].[ResourceTypeGuid])
    WHERE
       (
          (
             ([ajs13_rth].[BaseResourceTypeGuid] = @v7_BaseResourceType)
             AND
             ([ajs9_ouMem].[Distinguished Name] LIKE @v6_CurrentContainer)
             AND
             (
                ([vri8_Resource].[Name] LIKE @v2_var1)
                OR
                ([vri8_Resource].[Name] LIKE @v1_var2)
                OR
                ([vri8_Resource].[Name] LIKE @v5_var3)
                OR
                ([vri8_Resource].[Name] LIKE @v4_var4)
             )
          )
          AND
          ([vri8_Resource].[Guid] IN (SELECT [ResourceGuid] FROM [ScopeMembership] WHERE [ScopeCollectionGuid] IN (SELECT [ScopeCollectionGuid] FROM dbo.fnGetTrusteeScopeCollections(@v3_TrusteeScope))))
       )
    ORDER BY
       [Name] ASC,
       [Container] ASC
     



  • 4.  RE: Report Issue
    Best Answer

    Posted Feb 17, 2012 01:33 PM

    Computers can have multiple Video Controller drivers.  If you modify your query so that it says SELECT DISTINCT at the beginning, you will reduce the number of duplicate results, but still will return multiple rows for computers with multiple unique values for Installed display drivers.  This is because a computer can have multiple video controllers for multiple monitors and outputs.  You could restrict this by saying something like WHERE [Device ID]='VideoController1' or similar.



  • 5.  RE: Report Issue

    Posted Feb 20, 2012 02:01 PM

    Thats true, but sometimes I'm seeing one computer with 4-6 records.  Do you think it could be due to multiple monitors as well?  So if I have a computer with videocontroller1 and videocontroller2 and there are are 2 monitors I'm going to see 2 records per monitor.  I will see a record for vc1 on monitor 1&2 and a record for vc2 on monitor 1&2.



  • 6.  RE: Report Issue

    Posted Feb 20, 2012 04:03 PM

    If any column is different, you will have an additional row.