JPQL error in service bean

Hi,
I wrote a service with a simple select JPQL query and it worked fine in CUBA platform 6.6.4 release. But when I placed the service into a project built on 6.3.4 release I got this error:

com.haulmont.cuba.core.sys.jpql.JpqlSyntaxException: Errors found for input jpql:[select app from soesg$Application app where app.id <> :appId and ABS(app.place.latitude - :appLat) < :radius and ABS(app.place.longitude - :appLon) < :radius]
CommonErrorNode [<unexpected: [@23,69:71=‘app’,<55>,1:69], resync=ABS(app.place.latitude - :appLat) < :radius>]
CommonErrorNode [<unexpected: [@41,118:120=‘app’,<55>,1:118], resync=ABS(app.place.longitude - :appLon) < :radius>]

There is the service method:

public List<Application> loadApplicationsAround(Application app, double radius) {
    return persistence.callInTransaction(em -> em.createQuery("select app from soesg$Application app " +
            "where app.id <> :appId and ABS(app.place.latitude - :appLat) < :radius and ABS(app.place.longitude - :appLon) < :radius", Application.class)
            .setParameter("appId", app.getId())
            .setParameter("appLat", app.getPlace().getLatitude())
            .setParameter("appLon", app.getPlace().getLongitude())
            .setParameter("radius", radius)
            .setViewName("application-edit")
            .getResultList()
    );
}

What’s wrong? Maybe it is some known error fixed in later platform releases?

Yes, it is definitely a bug fixed in the more recent versions of the platform.