Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014aUaQeLnwbb1zTpN7kHeat
14 lines
495 B
Plaintext
14 lines
495 B
Plaintext
@AccessControl.authorizationCheck: #NOT_REQUIRED
|
|
@EndUserText.label: 'Energy of one park'
|
|
define view entity {{P}}I_PARK_POWER
|
|
as select from {{p}}turbine as turbine
|
|
inner join {{p}}prod as prod on prod.turbine_id = turbine.turbine_id
|
|
{
|
|
key turbine.turbine_id as turbine_id,
|
|
turbine.park_id as park_id,
|
|
sum( prod.energy_kwh ) as total_kwh,
|
|
count( * ) as day_count
|
|
}
|
|
where turbine.park_id = 'P01'
|
|
group by turbine.turbine_id, turbine.park_id
|