Catch only the value and format in 2 decimal places [closed]

-1

Well, I have a python script that queries two different bases for checking values per day, one in SQLSERVER and one in Postgres.

I used an if to tell if the values were different and if so, to warn.

What happens and what was alarming even though I consulted on the basis that they were the same.

When I started the result of the script variables, I came across this

How do I get only the value, without the decimal and character information and the format for only 2 decimal places?

    
asked by anonymous 07.11.2018 / 19:44

1 answer

1
cast(seu_campo AS NUMERIC(15, 2))
    
07.11.2018 / 20:27