cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with currency conversion CONVERT_CURRENCY in HANA SQL

TanmayVerma
Active Participant

Hi All,

I am executing the below query and able to get the result successfully:

SELECT
	 CONVERT_CURRENCY( "AMOUNT" => 1,
	 "SOURCE_UNIT" => 'JPY',
	 "TARGET_UNIT" => 'EUR',
	 "REFERENCE_DATE" => '20200212',
	 "ERROR_HANDLING" => 'set to null',
	 "CLIENT" => '400',
	 "SCHEMA" => 'SAPEPR',
	 "STEPS" => 'convert'  ) as abc 
FROM dummy;			  						

However when i am explicitly trying to provide configuration tables then i am getting an error:

SELECT
	 CONVERT_CURRENCY( "AMOUNT" => 1,
	 "SOURCE_UNIT" => 'JPY',
	 "TARGET_UNIT" => 'EUR',
	 "REFERENCE_DATE" => '20200212',
	 "ERROR_HANDLING" => 'set to null',
	 "CLIENT" => '400',
	 "SCHEMA" => 'SAPEPR',
	 "STEPS" => 'convert' ,
	 "CONFIGURATION_TABLE" => 'TCURV',
	 "PRECISIONS_TABLE" => 'TCURX',
	 "NOTATION_TABLE" => 'TCURN',
	 "RATES_TABLE" => 'TCURR',
	 "PREFACTORS_TABLE" => 'TCURF' ) as abc 
FROM dummy ;

I am getting the below error :

Could not execute 'SELECT CONVERT_CURRENCY( "AMOUNT" => 1, "SOURCE_UNIT" => 'JPY', "TARGET_UNIT" => 'EUR', ...' SAP DBTech JDBC: [328]: invalid name of function or procedure: CONVERT_CURRENCY: line 2 col 3 (at pos 10)

I am not able to understand where is the mistake even though the values i am providing are the default values of the paramters of CONVERT_CURRENCY.

Any pointers are will be helpful.

Regards,

Tanmay

View Entire Topic
former_member673606
Discoverer
0 Kudos

Hi All,

I am wondering if it's not possible to create currency conversion using HANA Calculation views of dimension or cube-type (w/o star join). When I am trying to convert the currency, it's returning the exact same amount. But when done in Star join, it's working, I don't understand, Kindly help

Regards,

Deba