2019 Jun 16 7:53 AM
How can I convert this query to sql sap Hana?
select txn_year,txn_month, sum(transaction_volume) as transaction_volume from (select year(from_unixtime(t.timestamp/1000)) as txn_year,MONTHNAME(from_unixtime(t.timestamp/1000)) as txn_month, count(t.id) transaction_volume from type_4 t
where t.assetId="EvN8cvuGKC2t1PA8ZEsgJth3paenSP4UAd8Z6K14z2P4" GROUP BY txn_month,txn_year union select year(from_unixtime(t.timestamp/1000)) as txn_year,MONTHNAME(from_unixtime(t.timestamp/1000)) as txn_month, count(t.id) transaction_volume from type_11 t
where t.assetId="EvN8cvuGKC2t1PA8ZEsgJth3paenSP4UAd8Z6K14z2P4" GROUP BY txn_month,txn_year ) sd GROUP BY txn_month,txn_year ORDER BY FIELD(txn_month,'January','February','March','April','May','June','July','August','September','October','November','December');
2019 Jun 17 1:59 AM
Hi jass kopov
Have you tried this tool - https://github.com/B1SA/HanaTranslator-Src to convert your query to SQL SAP Hana format?
Regards,
Sam