Skip to content

datastore: groupBy filtering fails #25

Description

@rakyll
/Users/jbd/gcloud-node/lib/datastore/entity.js:291
  query.groupBy = q.groupByVal.map(function(g) {
                               ^
TypeError: Object name has no method 'map'
    at Object.queryToQueryProto (/Users/jbd/gcloud-node/lib/datastore/entity.js:291:32)
    at Transaction.runQuery (/Users/jbd/gcloud-node/lib/datastore/index.js:263:19)
    at Dataset.runQuery (/Users/jbd/gcloud-node/lib/datastore/index.js:390:20)
    at Object.<anonymous> (/Users/jbd/gcloud-node/test.js:46:3)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)

Activity

  1. rakyll commented on Jul 21, 2014

    @rakyll
    ContributorAuthor

    It's caused by passing a field name to groupBy, rather than a list of field names.

    q.groupBy('name')

    groupyBy now arrayizes the first argument. Fixed on bb7a70a.

  2. modified the milestones: , Datastore Stable on Feb 2, 2015
  3. 83 remaining items

  4. added a commit that references this issue on Feb 17, 2026
  5. added a commit that references this issue on Feb 24, 2026
  6. added a commit that references this issue on Mar 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

🚨This issue needs some love.api: datastoreIssues related to the Datastore API.triage meI really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions