After a recent deployment of Sitecore 8.2 for one of our customers, we noticed that the “Reach” statistic when you open the “Personalized Experience” dialog in the Experience Editor was showing some numbers that were rather odd.
According to Sitecore documentation, the “Reach” statistic is defined as “the reach of the currently selected rule, which is expressed as the number of visitors that meet the condition and the percentage of all visitors that this number represents”. Seemed straightforward… The calculation for this metric is documented as “Reach = (Visitors that match the condition/All visitors) x 100”.
However, when we were looking at the numbers, things were definitely off. Although we were getting over 57,000 visits to the page that had the personalization rules set up, only 4,000 visitors triggered the default rule, and another 9 triggered a user-defined rule. Even more confusing was that the reach was calculated as 2% for the default rule and 98% for the user-defined rule.
So, I reached out to Sitecore Support to see if they could help. I was told this issue looked similar to something that was fixed in Sitecore 9, and so the instructions I received to resolve the issue were as follows:
- Navigate to the “/sitecore/system/Settings/Content Testing/Report Queries/Ruleset Exposure” item in the Sitecore Content Editor.
- Backup the existing SQL query in the Data field of that item (save it to a file, just in case).
- Replace SQL query in the Data field with this one:
SELECT [RuleId], SUM([Visitors]) as [Visitors] FROM [dbo].[Fact_RulesExposure] WHERE [Date] >= @StartDate AND [Date] <= @EndDate AND [ItemId] = @ItemId AND [RuleSetId] = @RuleSetId GROUP BY [RuleId]
- Save the changes.
Hope this helps. Just for reference, I also created a post on Sitecore Stack Exchange that you can take a look at.