I'm trying to set up a report in Sitecore Analytics that will report on the number of visitors split by members/non-members. I've looked in the Visitor and Visits tables but as far as I can see there's nothing that tells me if it was an anonymous user or not. Do I need to set up visitor profile to be able to get what I want, or is there a simpler way?
DMS has a field for this, Visitors.ExternalUser, but you need to write code to populate it. Include this code in your Login handler:
if (Tracker.IsActive)
{
Tracker.Visitor.ExternalUser = Sitecore.Context.User.DisplayName.ToLower();
}
You can then compare the number of visitors with this field populated to the total number of visitors.