Table data: sno name trans_date 1 Jon 2023-01-01 2 Sam 2023-01-02
I am trying to run a Postgresql SQL statement via psql -c. Statement looks like this
psql -c 'Select 1 from test_tab where trans_date = ''2023-01-01'' '
also same results for this statement: psql -c 'select 1 from test_tab where name = ''Jon'' '
I get results of same statememt when running in Dbeaver but in Shell terminal I get (0 rows). It seems like the issue is with single quote and I can't find any solution online. If I compare numbers it works, only issues is with characters and dates.