Loads and returns an array of entities of the specified entityname or an entity if unique=true or if a primary key id is passed in to filterCriteria.
entityLoad(entityName [,id | Filter ,unique | Order ,options])
→ returns any
Filter.id.AND keyword.
Order.Filter, then you can specify unique=true to return a single entity instead of an array. If you set unique=true and multiple records are returned, then an exception occurs.
unique.Filter and is sorted as specified by Order.Order parameter.false.ignorecase:,offsetmaxresultscacheablecachenametimeoutLoads an entity by primary key value
entityLoad("Employee", url.employee_id)
Expected Result: An Employee CFC Instance
Returns an array of Employee instances with last name Smith
entityLoad("Employee", {LastName="Smith"})
Expected Result: array
Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.