mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-13 22:54:51 +00:00
HHH-15266 Fix NPE during function logging due to wrong character_length alternative key registration
This commit is contained in:
parent
967ede47c0
commit
9351bcf30d
@ -1361,7 +1361,7 @@ public void length_characterLength_pattern(String clobPattern) {
|
||||
"character_length",
|
||||
new LengthFunction( "character_length", "character_length(?1)", clobPattern, typeConfiguration )
|
||||
);
|
||||
functionRegistry.registerAlternateKey( "character_length", "length" );
|
||||
functionRegistry.registerAlternateKey( "length", "character_length" );
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -292,6 +292,7 @@ public SqmFunctionDescriptor wrapInJdbcEscape(String name, SqmFunctionDescriptor
|
||||
}
|
||||
|
||||
public void registerAlternateKey(String alternateKey, String mappedKey) {
|
||||
assert functionMap.containsKey( mappedKey );
|
||||
log.debugf( "Registering alternate key : %s -> %s", alternateKey, mappedKey );
|
||||
alternateKeyMap.put( alternateKey, mappedKey );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user