I am using powershell command remotely to communicate with SharePoint Server(2010/13 both). I am using following powershell command to fetch "SiteGroups" from site collections
Get-SPSite http://server/sites/yoursite |
Select -ExpandProperty RootWeb |
Select -ExpandProperty SiteGroups |
Select {$_.ParentWeb.Url}, Name
But groups which are in a subsite inside a site collection also shown ParentWeb.Url as site collection URL. I want subsite's absoulte URL for those groups as those are belonging to subsite.
Can anybody suggest how to use get-spsite command to achieve this ? Does ParentWeb has any property which can give me absoulte URL of subsite ?