My PowerShell command is working fine as below :
PS C:\Users\username> whoami /userUSER INFORMATION----------------User Name SID================ ==============================================wip\username S-1-5-21-57989841-616248376-1811674531-4551702
But when I try to select only SID, it is showing blank
PS C:\Users\username> whoami /user | Select-Object "User information"User information----------------blank
I am expecting "S-1-5-21-57989841-616248376-1811674531-4551702" instead of blank