Vita1ij
Vita1ij

Reputation: 392

Sitecore Analytics error

I can't make Sitecore Analytics working. I have Sitecore 6.6.0 (rev. 121015) and installed Sitecore DMS.

1) when i go to Sitecore->Marketing Center i get error XML Parsing Error: no element found

2) when i go to Sitecore->Content Editor, choose element and press Analyze->Reports I get error You do not have permission to see any item reports

3) In Content Editor when press Analyze->Goals get Cannot use Analytics with a database that has no definition items error

4) in logs I see following:

"Exception: System.InvalidOperationException
Message: Cannot use Analytics with a database that has no settings"

5) If I change url that i get trying to open Marketing Center (changing Marketing%20Center.aspx to Marketing%20Center/default.aspx) I get Cannot use Analytics with a database that has no definition items error

6) I have in my Sitecore.Analytics.config this tag:

<setting name="Analytics.DefaultDefinitionDatabase" value="web" />

I tried to give access to analytics database from SQL Management Studio, but didn't help.

What could be the reason of this error, and how to solve it?

Upvotes: 1

Views: 3885

Answers (5)

jrap
jrap

Reputation: 364

The issue is due to Sitecore not being able to read the definition items in the master/web database (depending on the Analytics.DefaultDefinitionDatabase setting).

The items it is looking for are:

  • /sitecore/system/Marketing Control Panel
  • /sitecore/system/Settings/Analytics

When the request is running, the user is default\Anonymous. Using Access Viewer, make sure there are no security settings disabling read access to these items. This includes parent items that would have a trickle-down effect.

Upvotes: 0

Erwin Raets
Erwin Raets

Reputation: 53

I just erased my previous answer as that was a consequence of what was wrong, but not the actual cause...

In the Analytics code, the Marketing Center node is requested from the current database. If it cannot find that item (which IS in the master database), you get the error. But the code will NOT find the marketing center item if the security settings prevent the anonymous user read access...

That is where the error occured for me, when I was an anonymous user... And effectively, when looking at the security settings for the Marketing Center Item I found that inheritance had been blocked, hence preventing read access for the anonymous user...

Another reason this error sometimes occurs is when you have a production environment where there is no access to the master database. Since the Analytics code uses the "master" database as the default definition database unless otherwise specified in the config settings, you could add the following to analytics.config:

<setting name="Analytics.DefaultDefinitionDatabase" value="web" />

That way, it will fallback to the web database in case of a production environment without master database.

Hope this helps...

Erwin

Upvotes: 0

Mark Ursino
Mark Ursino

Reputation: 31435

Publish your site (to web). You might be trying to analyze data that isn't live.

Upvotes: 0

DougCouto
DougCouto

Reputation: 530

Your errors seem to suggest that the database is missing data. Did you use the database provided on this page, http://sdn.sitecore.net/Products/Sitecore%20V5/Sitecore%20CMS%206/Update/6_6_0_rev_121015.aspx ?

Go to the link above, scroll down to Download DMS 6.6.0 rev. 121015 for Sitecore CMS 6.6.0 rev.121015 and click the Download DMS 6.6.0 rev.121015 under SQL Server. Attach this database to your server and try again.

Upvotes: 1

Bryan
Bryan

Reputation: 8788

I haven't seen these errors, but it sounds to me like Sitecore is not able to access the Analytics database at all. You do have a connection string in ConnectionStrings.config named "analytics"? Try using the sa account just to make sure it's not a permissions issue. Don't forget to change it back from sa either way.

(caveat: I haven't used DMS yet, just OMS... it's possible I am way behind the times)

Upvotes: 0

Related Questions