Files
abap-llm/tasks_gen/eval/G0176/reference/i_station_energy.ddls.asddls

15 lines
450 B
Plaintext

@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Station energy totals'
define view entity {{P}}I_STATION_ENERGY
as select from {{p}}station as st
left outer join {{p}}session as se on se.station_id = st.station_id and se.status = 'C'
{
key st.station_id as station_id,
st.city as city,
count( se.session_id ) as session_count,
sum( se.energy_kwh ) as total_energy
}
group by
st.station_id,
st.city