I'm having a really weird issue running a timestamp comparison query in my postgresql database.
I have a table called user (I know it's a terrible name) and we have a column named createdAt that's the type of timestamp with timezone. I should be able to run a query comparing against this column no problem. Yet, the WHERE in this clause (and the AND) don't seem to have any effect. I get back every single user from this table including ones with a null value in the createdAt column. I'm perplexed.
select * from "user"
where 'createdAt' >= '2017-08-01 23:25:53+00'
and 'createdAt' is not null
order by id desc;
EDIT:
relevant table structure and sample data
*** table columns ***
id serial primary key
createdAt timestamp with time zone
first_name text
last_name text
** sample data ***
id first_name last_name createdAt
1 john smith 2018-09-21 02:53:42+00
2 james smith 2018-09-19 00:27:14+00
EDIT: SOLVED
This was a weird issue but I wasn't getting any feedback from my where clause. The problem is the original devs named the columns camel cased which makes it necessary that any future queries referencing this column use the double quotes. Ended up having to say "user"."createdAt". That was a syntax issue on my part since I only ever name my columns snake case.