Yair Zaslavsky has submitted this change and it was merged.

Change subject: core: Underscores in tag names break tags
......................................................................


core: Underscores in tag names break tags

Since '_' is treated in Postgres as '?' when using like, (i.e. match
any single character)
we have to escape this character in the value to make it
treated as a regular character.
Due to changes between PG8.x and PG9.x on ESCAPE
representation in a string, we should
figure out what PG Release is running in order to escape
the special character(_) correctly

The bug was that the above treatment was done on the value no matter
what the operator is, while this change should be applied only for the
LIKE or ILIKE operator. If the operator is '=' '!=' 'IN' etc. the '_'
should stay as is in the passed value and not been manipulated.

Change-Id: Ia4c289e198b59afc4acf3e671ea65f2cdf8e31ad
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=949484
Signed-off-by: Eli Mesika <[email protected]>
---
M 
backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/SyntaxChecker.java
1 file changed, 17 insertions(+), 16 deletions(-)

Approvals:
  Yair Zaslavsky: Verified; Looks good to me, approved


-- 
To view, visit http://gerrit.ovirt.org/15594
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia4c289e198b59afc4acf3e671ea65f2cdf8e31ad
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Eli Mesika <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to