[prev in list] [next in list] [prev in thread] [next in thread]
List: postgresql-admin
Subject: Re: btree/gist index on date and searching using BETWEEN or >= and <=
From: Tom Lane <tgl () sss ! pgh ! pa ! us>
Date: 2023-09-12 0:08:14
Message-ID: 2697607.1694477294 () sss ! pgh ! pa ! us
[Download RAW message or body]
Wells Oliver <wells.oliver@gmail.com> writes:
> Is there a meaningful difference index/plan-wise searching where DATE
> BETWEEN x AND y versus DATE >= x AND DATE <= y?
Nope.
> Secondly, would btree be the best index for such a column, or gist/etc?
btree. gist can sort of do scalar-inequality searches, but they're
not its strength.
regards, tom lane
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic