CF Snippets

Select query using named datasource

If you do not have a default datasource configured, you'll need to use this variant to specify which datasource to use.

var queryOptions = { datasource: "appMain" };
var data = queryExecute(
  "SELECT * FROM users", {}, queryOptions
);