SCCM report to list all computers based on last logged on user name from collection

If you want to trace the users on what computers are they logged in(please be noted that  this is based on the hardware inventory information and if multiple users logged into same computer will not report to site server until inventory information sent).

Take a look at this post for more information about explaining last logged on user name http://smsug.ca/blogs/garth_jones/archive/2007/06/30/482.aspx

select distinct a.Name0,a.UserName0 from v_GS_COMPUTER_SYSTEM a,v_FullCollectionMembership b where a.username0=@username and b.CollectionID=@COLLID

Prompt for username:

select distinct username0 from V_GS_Computer_system order by username0

prompt for COLLID :

select  CollectionID,Name from v_Collection

 

if you need the last logged on user information from a given collection,you can try the below report :

select distinct a.Name0,a.UserName0 from v_GS_COMPUTER_SYSTEM a,v_FullCollectionMembership b where  b.CollectionID=@COLLID

prompt for COLLID :

select CollectionID,Name from v_Collection

 

9 Responses to "SCCM report to list all computers based on last logged on user name from collection"

  1. I will right away grasp your rss feed as I can't to find your e-mail subscription hyperlink or newsletter service. Do you have any? Kindly permit me recognize so that I may subscribe. Thanks.

    Reply
    1. Did you create prompt for Username which is declared in report ?
      select distinct username0 from V_GS_Computer_system order by username0

      Reply
  2. I am trying to add your query but it gives me an error. I am a little new to this. how do you add the info above to create the query?
    Any help would be greatly appreciated.

    thanks

    Reply

Leave a Reply