Re: Query not producing expected result
От
Tom Lane
Тема
Re: Query not producing expected result
Дата
Msg-id
25696.1556728884@sss.pgh.pa.us
Ответ на
Query not producing expected result (Chuck Martin)
Список
Дерево обсуждения
Query not producing expected result Chuck Martin <clmartin@theombudsman.com>
Re: Query not producing expected result Tom Lane <tgl@sss.pgh.pa.us>
Re: Query not producing expected result Chuck Martin <clmartin@theombudsman.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Chuck Martin <clmartin@theombudsman.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result Chuck Martin <clmartin@theombudsman.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Chuck Martin <clmartin@theombudsman.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result Francisco Olarte <folarte@peoplecall.com>
Re: Query not producing expected result Adrian Klaver <adrian.klaver@aklaver.com>
Re: Query not producing expected result "David G. Johnston" <david.g.johnston@gmail.com>
Re: Query not producing expected result Julien Rouhaud <rjuju123@gmail.com>
Re: Query not producing expected result Ron <ronljohnsonjr@gmail.com>
Chuck Martin writes: > I need help figuring out why a query is not returning the records I expect > it to. I'm searching on a DateTime column (timestamp without time zone - > not nullable). The query includes: > AND event.Primaryresp_fkey = 5000011 AND event.DateTime <= 'May-1-2019' > AND event.EventDone < 1 > This does not return a record that has a DateTime value "May 1, 2019 9:52 > AM". Well, no, since the implied value of the constant is 'May-1-2019 00:00'. If you only want 1-day precision of the comparison, maybe you should cast or truncate the timestamp down to date. regards, tom lane
В списке pgsql-general по дате отправления