HANA Studio has a default format option (Preferences>Runtime>Result>'Format Values').
Ex: A View Column of Decimal(13,3) outputs 30 in Data Preview with 'Format Values' setting, and 30.000 without 'Format Values' setting.
Tableau displays it as 30.000, but Python hdbcli always returns 30 regardless of setting.
I intend to run many queries, therefore casting each column in SQL or Python is not desireable.
Is there a HANA System setting or hdbcli setting to configure output to always get the unformatted option?
It seems to me that there is a misunderstanding here about when and where (in the sequence of processing steps) the formatting of values is done.
From the context of the question I assume that the OP used functions like
print(df[column_name])to inspect the format of values.In this scenario the formatting occurs right before outputting to the terminal; but importantly not during the processing of data in HANA, during the network transfer, or the mapping to Python data structures.
That means, there is neither the need nor the option to improve processing efficiency by switching off potentially unnecessary formatting.
Instead, the output format only applies to when values are in fact rendered to a printable string. And for this the string formatting options on Python can be used to get the desired output format.
This is valid for all DBMS used with Python; not just for HANA.