You may want to take a look at some of the How To... sections of the help especially the Filtering and Sorting section for additional information on any queries you are trying to create.
Since you are using an object fetch the duplicates are automatically filtered out. You can then sort your collection on the client side using...
Dim filter As New RelationPredicateBucket
adapter.FetchTypedView(invoices.GetFieldsInfo(), invoices, bucket, 0, sorter, True)
filter.Relations.Add(ProductEntity.Relations.ProductModuleEntityUsingProductId)
filter.Relations.Add(ProductModuleEntity.Relations.ModuleEntityUsingModuleId)
filter.Relations.Add(ModuleEntity.Relations.GroupModuleEntityUsingModuleId)
filter.Relations.Add(GroupModuleEntity.Relations.GroupEntityUsingGroupId)
filter.PredicateExpression.Add(PredicateFactory.CompareValue(ProductFieldIndex.ProductId, ComparisonOperator.Equal, productId))
Dim adapter As New DataAccessAdapter
Dim groups As New EntityCollection(New GroupEntityFactory)
adapter.FetchEntityCollection(groups, filter)
groups.Sort(CType(GroupFieldIndex.Description, Integer), ListSortDirection.Descending)