PDQ Inventory SQL Query

Comments

2 comments

  • Colby Bouma

    I did some experimenting, and it looks like <ComputerFilter> can't handle the Computers table being renamed. Also, I added Applications.Version to the GROUP BY clause so versions don't get swallowed.

    SELECT 
          Applications.Name as 'Application Name'
        , Applications.Version
        , COUNT(Applications.Name) as 'Count'
        , GROUP_CONCAT(Computers.ComputerID, ', ') AS 'Computer ID' 
    FROM
        Computers
    JOIN
        Applications USING (ComputerID) 
    WHERE
            Applications.Name IN (
                  'Microsoft Edge'
                , 'PDQ Deploy'
            )
        AND
            <ComputerFilter>
    GROUP BY
          Applications.Name
        , Applications.Version
    ORDER BY
        Count
    2
    Comment actions Permalink
  • Peter Brooks

    That worked, thankyou!!

    0
    Comment actions Permalink

Please sign in to leave a comment.