coldbox-modules / cborm

The ColdBox ORM enhancements for ColdFusion ORM & Hibernate. Make ORM not suck!
https://coldbox-orm.ortusbooks.com/
8 stars 17 forks source link

exists() Method Concerns #24

Closed jclausen closed 5 years ago

jclausen commented 5 years ago

exists() in BaseORMService is not universally functional because the property name of id is hard coded in to the HQL.

In addition, this method will not work on entities which have an entity name which is a reserved word in the DBMS platform ( e.g. Case ).

The key property should be dynamically retrieved for the HQL in ormExecuteQuery.

In addition, investigate if there is a ways to provide escaping for entities and property names which are reserved words : e.g [Case] for SQL Server, "Case" for MySQL and Postgres, etc

lmajano commented 5 years ago

This is fixed now