Escaping : with :: in queries

Description

Since colons in queries in hibernate currenlty are non-escapable I created a patch (see http://forum.hibernate.org/viewtopic.php?p=2275131#2275131) to make it possible to escape the colon with itself. I needed to do this since I'm using Informix with native sql queries where I'm joining tables from two databases together. In informix you do this by specifiying <database-name>:<table-name> and that didn't work in hibernate since hibernate has reserved the colon for named parameters.

Environment

Hibernate 3, Informix 9.4

Activity

Show:
Michael Schnell
August 23, 2015, 12:18 PM
Edited

Unfortunately no maintainer of the Hibernate ORM repository integrated it into the branch. Now it's not possible to merge it automatically.

I cancelled the old one and created a new pull request: https://github.com/hibernate/hibernate-orm/pull/1058

In the meantime you can check out the Hibernate code from Github and change it yourself manually. It's no big thing as it's just a minimal change: https://github.com/michael-schnell/hibernate-orm/commit/985697c49d60358a3178a2ad27ddf7df0ed7b100

Gail Badner
April 12, 2016, 8:52 PM

, thanks for the PR. We still need a test case added to it though...

Michael Schnell
April 23, 2016, 11:06 AM

One more try... Now with test case: https://github.com/hibernate/hibernate-orm/pull/1352

Vlad Mihalcea
April 26, 2016, 7:10 AM

Applied PR on master and 5.1.

Vlad Mihalcea
April 26, 2016, 7:12 AM

Would you like to have this minor fix integrated on 5.0 branch too?

Fixed

Assignee

Vlad Mihalcea

Reporter

Steinar Dahl

Fix versions

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Minor
Configure