Skip to content

Commit

Permalink
Fix collate clause for prefix match
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmed-shameem committed Jan 30, 2025
1 parent 780e8e0 commit 05b7ac9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion contrib/babelfishpg_tsql/src/collation.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,7 @@ transform_from_ci_as_for_likenode(Node *node, OpExpr *op, like_ilike_info_t like
}

patt = (Const *) rightop;
patt->constcollid = op->inputcollid;

/* extract pattern */
pstatus = pattern_fixed_prefix_wrapper(patt, 1, coll_info_of_inputcollid.oid,
Expand Down Expand Up @@ -760,7 +761,7 @@ convert_node_to_funcexpr_for_like(Node *node, Oid inputCollOid)
Node *new_node;
newFuncExpr->funcid = remove_accents_internal_oid;
newFuncExpr->funcresulttype = get_sys_varcharoid();
newFuncExpr->inputcollid = newFuncExpr->funccollid = inputCollOid;
newFuncExpr->funccollid = inputCollOid;

if (node == NULL)
return node;
Expand Down

0 comments on commit 05b7ac9

Please sign in to comment.