leonhardt
08/08/2023, 5:37 PMleonhardt
08/08/2023, 5:37 PMTIMESTAMP.leonhardt
08/08/2023, 5:38 PMjava.time.Instant to use as a TIMESTAMP.leonhardt
08/08/2023, 5:38 PMorg.postgresql.util.PGInterval. Maybe SQLDelight doesn't understand the context of the parameter well enough.leonhardt
08/08/2023, 5:38 PMhfhbd
08/08/2023, 5:38 PMhfhbd
08/08/2023, 5:41 PMleonhardt
08/08/2023, 5:43 PMAND sessionRecord.created_at = CAST(:now AS TIMESTAMP)
(in fact the CAST isn't necessary here)
but in this case:
AND sessionRecord.created_at > CAST(:now AS TIMESTAMP) - INTERVAL '28 days'
the resulting now parameter is still coming up as a org.postgresql.util.PGInterval.hfhbd
08/08/2023, 5:47 PMleonhardt
08/08/2023, 5:48 PMhfhbd
08/08/2023, 5:50 PMleonhardt
08/08/2023, 5:55 PMjava.time.Instant and uses it as a TIMESTAMP within the above query. Specifying the type was just the latest thing I was trying along the way.
I suppose I had assumed that would be the solution but I'm open to changing any syntax or approach you might suggest!hfhbd
08/08/2023, 6:00 PMleonhardt
08/08/2023, 6:00 PMleonhardt
08/08/2023, 6:08 PMleonhardt
08/24/2023, 2:33 PMhfhbd
08/24/2023, 7:28 PMleonhardt
08/24/2023, 7:29 PM