My Oracle Support Banner

EclipseLink namedQuery NULL parameter passed as '=NULL', fails to return rowset (Doc ID 1937523.1)

Last updated on JUNE 28, 2021

Applies to:

Oracle TopLink - Version 12.1.2.0.0 to 12.1.2.0.0 [Release 12c]
Information in this document applies to any platform.

Symptoms

When upgrading a Weblogic Kodo persistence application to EclipseLink, an issue is noted with named queries using parameters that have NULL values. If a parameter is specified as IS NULL, a select statement always returns an empty result back with EclipseLink even though there are the records in the database. It is noted that the same query returns records in Kodo.

For example an entity with some fields that are nullable and a named query that uses them in the query:

 

If :givenid IS NULL the above select statement always return an empty result back with EclipseLink even though there are the records in the database.

Changes

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution
References

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.