Hello good day I want to know how I can make a condition I have this problem when in a query rest field1-field2 in the condition I must bring only when there are differences, however there is a difference sometimes I get 0.01 or -0.01 if that comes out as a result I ignore it I have the query as follows:
SELECT CAMPO1-CAMPO2 FROM RESTA WHERE (CAMPO1-CAMPO2)>0
I want the query that brings me if the rent was 0 difference but if there is a range of 0.01 or negative I ignore it in the query, I did it using cast to work with integers but I do not serve
SELECT CAST((CAMPO1-CAMPO2) AS INT) FROM RESTA WHERE CAST((CAMPO1-CAMPO2) AS INT)>0
someone to help me with another way of doing it