I support an ETL process that converts the input of a flat file to a SqlServer database table. The code is almost 100% T-SQL and works inside the database. I do not own the code and cannot change the workflow. I can only help set up an SQL "translation" that takes file data and converts it to table data (more on that later).
Now that the disclaimer ...
One of our file providers has recently changed how they represent a monetary amount from '12345.67' to '12,345.67' . Our SQL, which converts the value, looks like SELECT FLOOR( CAST([inputValue] AS DECIMAL(24,10))) and does not work anymore. I., comma breaks cast.
Given that I need to save the final value as a Decimal (24,10) datatype (yes, I understand that FLOOR erases all precision after the decimal point - the designer did not synchronize with the client), what can I do to use this line effectively? ''
Thanks for your ideas.
casting tsql
Setho
source share