Open mtandersson opened 9 years ago
Hi @mtandersson Thanks for the suggestion. cc @sgiehl
Adding a segment for that is not that easy as we do not store the family in the log tables. That means we would need to map the given family to the os short codes it contains and search for those instead
@sgiehl does Device Detector has the map of OS Short code <-> OS Family? if we have this map, then we can create a callback and use it in the segment metadata with: setSqlFilterValue
as in this example: https://github.com/piwik/piwik/blob/master/plugins/Referrers/Columns/ReferrerType.php#L27-27 or: https://github.com/piwik/piwik/blob/master/plugins/API/API.php#L162-162
@mattab I don't think it's that easy. There is a mapping for OSFamily => OSShortCodes. So there may be more than one short code in a family. Your examples provide a 1:1 mapping.
So there may be more than one short code in a family.
that's alright, the segment would then do browser_code IN ( val1, val2, val3, val4 )
But i'm not sure if this is already implemented and easy to do... will need to check later (moving to Mid term)
Segementing data is nice! It would be even better if it would be possible to segment on Operating System families