VMware Cloud Community
nmernaci
Contributor
Contributor

How can I query "Users and Groups" Usernames + Sessions numbers?

pastedImage_0.png

So far I have been able to only query the session count using the following:

$query.queryEntityType = 'EntitledUserOrGroupLocalSummaryView'

$qSRv.QueryService_Query($global:DefaultHVServers[0].ExtensionData,$query) |

Select -ExpandProperty Results |

Select -ExpandProperty sessionData

However, as you can see it does not pull the User Names, only SessionCount:

pastedImage_2.png

0 Kudos
2 Replies
LucD
Leadership
Leadership

0 Kudos
nmernaci
Contributor
Contributor

Hey LucD,

While that is helpful it's not exactly what I'm looking for. (I actually came upon that post in my google search earlier and it is useful, so thank you for that).

However, the query I need for what appears on the Users and Groups tab. The Users and Groups displays total sessions for each User Name (See below).

pastedImage_0.png

Thank you

0 Kudos