Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

find adds the id column automatically with no easy way to remove it #251

Open
2 tasks done
jordanbtucker opened this issue Jun 29, 2020 · 1 comment
Open
2 tasks done
Labels

Comments

@jordanbtucker
Copy link

Steps to reproduce

(First please check that this issue is not already solved as described
here
)

  • Tell us what broke. The more detailed the better.
  • If you can, please create a simple example that reproduces the issue and link to a gist, jsbin, repo, etc.

find will always return records with an id, and while this is often useful, it makes it difficult to customize the query with something like distinct or group by.

An example, including a workaround, are available at https://gist.github.com/jordanbtucker/30d403170e3104b841f7195d25ba6101.

Expected behavior

There should be a way to remove the id column from a query.

Actual behavior

The id column is included in queries, which is problematic when you want to alter the query with something like distinct as explained in Customizing the query.

System configuration

Module versions (especially the part that's not working):

"feathers-knex": "^7.1.0",
"knex": "^0.21.1",
"mysql": "^2.18.1",

NodeJS version:

v12.18.1

@stale
Copy link

stale bot commented Oct 4, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Apologies if the issue could not be resolved. FeathersJS ecosystem modules are community maintained so there may be a chance that there isn't anybody available to address the issue at the moment. For other ways to get help see here.

@stale stale bot added the wontfix label Oct 4, 2020
@daffl daffl added bug and removed wontfix labels Oct 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants