Skip to Content
0
Jun 04, 2020 at 10:04 AM

SAP B1 HANA QUERY ADD CONSTANT VALUE USING SELECT FROM DUMMY UNION ALL

619 Views

I am trying to add several lines of constant values to existed query, the result can be executed, but in pervasive analysis, the data cannont be sum, average, it only can be count.

For example, I would like to add a new dashboard using pervasive analysis which can SUM the total Commercial Amount by Project.

The query will start with 3 lines of constant values, then union the values from OINV, OPOR,ORDR

CONSTANT VALUES:

SELECT

'AAA' "Project",

'18998.10' "Commercial Amount",

'FOB' "Price term" ,

'18998.10' "Proforma Amount",

'17271.00' "Purchase Amount"

FROM DUMMY

UNION ALL

'AAA' "Project",

'18998.10' "Commercial Amount",

'FOB' "Price term" ,

'18998.10' "Proforma Amount",

'17271.00' "Purchase Amount"

FROM DUMMY

UNION ALL

'BBB' "Project",

'18998.10' "Commercial Amount",

'FOB' "Price term" ,

'18998.10' "Proforma Amount",

'17271.00' "Purchase Amount"

FROM DUMMY

Thanks

Alicia