Summary Row for a SQL HANA Query Error

2 months ago 17

Dear Experts,

I americium trying to update an SQL HANA query to see the summary enactment for a mates of columns.  I americium utilizing the UNION ALL method to get the summary, individually the 2 queries are moving fine, but erstwhile executed unneurotic I get an beneath error.

Below query::

SELECT T2."Indicator",T0."DocNum",T0."TaxDate" "Doc Date",DAYS_BETWEEN(T0."TaxDate",CURRENT_DATE) "No. Of Days",T0."CardName", T0."NumAtCard",
cast(T3."InsTotal" arsenic integer) AS "Total Amount",cast(T3."InsTotal"-T3."PaidToDate" arsenic integer) AS "Open Amount", T1."SlpName"
FROM ORDR T0
INNER JOIN RDR6 T3 ON T0."DocEntry"=T3."DocEntry"
INNER JOIN OSLP T1 ON T0."SlpCode" = T1."SlpCode"
INNER JOIN OPID T2 ON T0."PIndicator" = T2."Indicator"
WHERE DAYS_BETWEEN(T0."TaxDate",CURRENT_DATE)>365 and T0."CANCELED"='N' and T0."DocStatus"='O'
UNION ALL
SELECT '','','','','','Total',
sum(T3."InsTotal"),sum(T3."InsTotal"-T3."PaidToDate"),''
FROM ORDR T0
INNER JOIN RDR6 T3 ON T0."DocEntry"=T3."DocEntry"
INNER JOIN OSLP T1 ON T0."SlpCode" = T1."SlpCode"
INNER JOIN OPID T2 ON T0."PIndicator" = T2."Indicator"
WHERE DAYS_BETWEEN(T0."TaxDate",CURRENT_DATE)>365 and T0."CANCELED"='N' and T0."DocStatus"='O'

on executing one americium getting the beneath mistake :

SAP DBTech JDBC: [339]: invalid number: Failed to parse constant

Read Entire Article