Code: Alles auswählen.
TYPES: BEGIN OF ty_erg,
auart TYPE auart,
anz TYPE i,
END OF ty_erg.
DATA lt_erg TYPE STANDARD TABLE OF ty_erg.
DATA ls_erg TYPE ty_erg.
SELECT auart COUNT( * ) AS anz
FROM vbak
INTO TABLE lt_erg
GROUP BY auart.
SORT lt_erg BY anz DESCENDING.
LOOP AT lt_erg INTO ls_erg FROM 1 TO 6.
WRITE: / ls_erg-auart, ls_erg-anz.
ENDLOOP.
Code: Alles auswählen.
SELECT page_name COUNT( * ) as Anzahl
FROM A
INTO CORRESPONDING FIELDS OF TABLE ba_tbl
WHERE created_at BETWEEN lv_timestamp AND lv_timestamp2.
GROUP BY page_name.
Code: Alles auswählen.
SELECT page_name COUNT( * ) as Anzahl
FROM A
INTO CORRESPONDING FIELDS OF TABLE ba_tbl
WHERE created_at BETWEEN lv_timestamp AND lv_timestamp2.
GROUP BY page_name.
Code: Alles auswählen.
SELECT COUNT(*)
FROM /BAY0/MS_DSLOG
INTO x
where page_name = p_pgname
and created_at between lv_timestamp and lv_timestamp2[b].[/b]
group by page_name.