Skip to content
Advertisement

Get rows within current month

Get the rows from a table filtered by current month in psql.

Example table –

After query result, assuming current month is July, 2020:

Advertisement

Answer

The usual approach is to use a range query to allow for an index usage on registration_date

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement