Skip to content

Miscellaneous

findAllKeys()

findAllKeys() — returns any

Returns all primary key values in a list. In addition to quoted and delimiter you can pass in any argument that findAll() accepts.

NameTypeRequiredDefaultDescription
quotedbooleanyesfalseSet to true to enclose each value in single-quotation marks.
delimiterstringyes,The delimiter character to separate the list items with.
// basic usage
primaryKeyList = model("artist").findAllKeys();

// Quote values, use a different delimiter and filter results with the "where" argument
primaryKeyList = model("artist").findAllKeys(quoted=true, delimiter="-", where="active=1");