Skip to main content

system.kanoa.operators.getOLEDataByInterval(userId, assetId, startDate, endDate, interval, attributionMode)

Returns bucketed (Hour/Day/Week) OLE/POLE data for one user on one asset, or for every operator scheduled or logged into the asset anywhere in the range when userId is None (one row per operator per bucket)


Parameters

userId Integer: Id of user, or None to return one row per operator per bucket for this asset/period
assetId Integer: Id of asset
startDate DateTime: Start date
endDate DateTime: End date
interval String: i.e 'Hour', 'Day', 'Week', None - If None, interval will be auto calculated based on the range length
attributionMode String: 'EvenSplit', 'FullCredit', or 'PrimaryOnly' - controls how counter output is split when the asset has a crew (multiple concurrent users). Default 'EvenSplit'.


Returns

oleData pyDataset


Example

userId = None
assetId = 4
startDate = system.date.parse("2025-11-01 00:00:00")
endDate = system.date.parse("2025-11-05 00:00:00")
interval = 'Hour'
attributionMode = 'EvenSplit'
data = system.kanoa.operators.getOLEDataByInterval(userId, assetId, startDate, endDate, interval, attributionMode)