My code that ran perfectly in my accademy computer kept saying I have ORA-01861: literal does not match format string error.
This was because Korea's Date default format is "yyyy-mm-dd", but US's format is different. Accademy's format is Korea, and my laptop's is US. So this made the error.
I had to use to_date(contentDate,'yyyy-mm-dd') and it worked.
I did
String sql= "select contentTime from contentTime where contentDate=to_date(?,'yyyy-mm-dd');