Archiving and displaying data from an own database table


Actually I am working on an Plugin that tracks custom data into an own database table. This data would be logged via an HTTP Connection and not when the user is interacting with the website.

First I thought the Goals Plugin is an reference, but then I noticed that some stuff the Plugin should do, is added to the Piwik Core. That’s very confusing for me.

How I could handle this custom data and how to add it to the database I figured out myself, but now I am struggling again with the archiving and the output of this data in the piwik backend. Displaying ths data with the help of some plain SQL statements isn’t a way that I prefer.

(Matthieu Aubry) #2

You should use the new Custom Variables feature in Piwik: see the 1.2-rc release post: 301 Moved Permanently


This is not an Solution for my problem. The data i want to track is recorded via an http request to piwik when a user has started an process in our system. After the completion of this process we want to save some stats into piwik.

The visitor is excluded, and the json data will be decoded and saved to an separate table in the database. My question is: What is the best practice to archive and display data from an completely separate database table?

(Matthieu Aubry) #4

it depends on what you want to display with your data, what reports you need. For the UI part, check out the ExampleUI plugin which shows how to reuse tables and graphs.


I started working without reading and using my head!
Now it works :wink: Thank you!