Yes, there are alot of post on this topic, but all of them seem to be in regards to inserting data. I am in need of pulling data.
I just found what the problem is but I have not found out how to write it out correctly. have a prepared statement that I found in one of our projects that does not work.
I have traced it down to where we are checking if a date is >= x AND <= Y.
I have been on this problem literally all day.
statement.append("SELECT error_code FROM dw.transaction_error_logs");
statement.append(" WHERE activity_timestamp >= '?'");
statement.append(" AND activity_timestamp <= '?'");
The DB is Postgres and the column is type 'timestamp with time'. I have tried it without the quotes but then I get errors with the characters being passed as the values are like '2015-11-12 17:37:45'