Replies: 2 comments
-
Hello @rcc247, It looks like a database issue and has nothing to do with DBeaver. Please take a look at the database manual. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Description
I applied the FLOOR function on a column that included some decimal values between 0 and -1 (non inclusive). I was expecting the FLOOR function value to come out as -1, but the query result showed 0 instead. I tried a separate query that applied the FLOOR function to the exact same negative value as a literal/static value and it calculated correctly as -1. So I'm "doubly puzzled" why FLOOR applied to a column didn't work reliably but FLOOR applied to an equivalent static value worked.
DBeaver Version
Community Edition 23.1.1.202306251800
Operating System
Windows 11 Pro
Database and driver
AWS / Redshift, PostgreSQL
AWS Redshift JDBC driver, Classname: com.amazon.redshift.jdbc42.Driver
Steps to reproduce
I have an active connection to a database that includes a table with a column having decimal values, including some values between 0 and -1.
My query includes a calculated column using the FLOOR function.
I run the query.
The query results include rows where the original column value is between 0 and -1 (non inclusive) and the calculated (FLOOR) column value is 0 instead of the expected -1 value.
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions