Doug,
Yes, it does depend on the locale, you can get around this in 7.4 by
building the index with smart operators
Dave
On Thu, 2003-12-18 at 20:38, Doug McNaught wrote:
> Christopher Kings-Lynne <[EMAIL PROTECTED]> writes:
>
> >> It appears that the optimizer only uses indexes for = clause?
> >
Christopher Kings-Lynne <[EMAIL PROTECTED]> writes:
>> It appears that the optimizer only uses indexes for = clause?
>
> The optimizer will used indexes for LIKE clauses, so long as the
> clause is a prefix search, eg:
>
> SELECT * FROM test WHERE a LIKE 'prf%';
Doesn't this still depend on your
Hello,
i got indexes to work with "text_pattern_ops" for locale et_EE.
So instead of:
create index some_index_name on some_table(some_text_field);
nor
create index some_index_name on some_table(some_text_field text_ops);
try to create index as follows:
create index some_index_name on some_
Dave Cramer <[EMAIL PROTECTED]> writes:
> So even in a north-american locale, such as en_CA this will be a
> problem?
If it's not "C" we won't try to optimize LIKE. I know en_US does not
work (case-insensitive, funny rules about spaces, etc) and I would
expect en_CA has the same issues.
If you'r
So even in a north-american locale, such as en_CA this will be a
problem?
Dave
On Thu, 2003-12-18 at 22:44, Tom Lane wrote:
> Dave Cramer <[EMAIL PROTECTED]> writes:
> > after vacuum verbose analyze, I still get [a seqscan]
>
> The other gating factor is that you have to have initdb'd in C locale
Dave Cramer <[EMAIL PROTECTED]> writes:
> after vacuum verbose analyze, I still get [a seqscan]
The other gating factor is that you have to have initdb'd in C locale.
Non-C locales tend to use wild and wooly sort orders that are not
compatible with what LIKE needs.
regards
On Thu, 18 Dec 2003, Dave Cramer wrote:
> after vacuum verbose analyze, I still get
>
> explain select * from isppm where item_upc_cd like '06038301234';
> QUERY PLAN
> ---
> Seq Scan on isppm (cos
[EMAIL PROTECTED] (Dave Cramer) wrote:
> It appears that the optimizer only uses indexes for = clause?
It can use indices only if there is a given prefix.
Thus:
where text_field like 'A%'
can use the index, essentially transforming this into the clauses
where text_field >= 'A' and
after vacuum verbose analyze, I still get
explain select * from isppm where item_upc_cd like '06038301234';
QUERY PLAN
---
Seq Scan on isppm (cost=1.00..19684.89 rows=2 width=791)
Fil
It appears that the optimizer only uses indexes for = clause?
The optimizer will used indexes for LIKE clauses, so long as the clause
is a prefix search, eg:
SELECT * FROM test WHERE a LIKE 'prf%';
Chris
---(end of broadcast)---
TIP 4: Don't 'kil
10 matches
Mail list logo