mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-02-02 10:00:38 +01:00
Fixed some issues with expression indices.
This commit is contained in:
parent
9528b400c4
commit
0551c0fcb6
@ -3319,6 +3319,15 @@ static bool expression_equal2(thread_db* tdbb, OptimizerBlk* opt,
|
||||
case nod_current_timestamp:
|
||||
return true;
|
||||
|
||||
case nod_between:
|
||||
case nod_like:
|
||||
case nod_missing:
|
||||
case nod_any:
|
||||
case nod_ansi_any:
|
||||
case nod_ansi_all:
|
||||
case nod_not:
|
||||
case nod_unique:
|
||||
|
||||
case nod_value_if:
|
||||
case nod_substr:
|
||||
{
|
||||
@ -6485,8 +6494,8 @@ static jrd_nod* make_starts(thread_db* tdbb,
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
#endif
|
||||
{
|
||||
if (field->nod_type != nod_field)
|
||||
{
|
||||
// dimitr: any idea how we can use an index in this case?
|
||||
@ -6499,9 +6508,6 @@ static jrd_nod* make_starts(thread_db* tdbb,
|
||||
value = boolean->nod_arg[0];
|
||||
*/
|
||||
}
|
||||
#ifdef EXPRESSION_INDICES
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Every string starts with an empty string so
|
||||
don't bother using an index in that case. */
|
||||
@ -6528,6 +6534,7 @@ static jrd_nod* make_starts(thread_db* tdbb,
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
jrd_nod* node = make_index_node(tdbb, relation, opt->opt_csb, idx);
|
||||
IndexRetrieval* retrieval = (IndexRetrieval*) node->nod_arg[e_idx_retrieval];
|
||||
|
Loading…
Reference in New Issue
Block a user