between operator

Hello i have a table where i have 2 columns where i save timestamps (epoch time) as integer. when i try to query it with the between operator i get no response. .where(between(1697013797353, table.startDate, table.endDate)) the number gets red underlined. Also when i use sqlCURRENT_TIME and so on it doesnt work either. Any idea anyone? Thanks!
2 Replies
Angelelz
Angelelz14mo ago
It might not be correct sql syntax You could try
.where(between(sql`1697013797353`, table.startDate, table.endDate))
.where(between(sql`1697013797353`, table.startDate, table.endDate))
I'm not sure that's going to work
louis
louisOP14mo ago
got it working thank you!
Want results from more Discord servers?
Add your server