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

Select filter is ignored by sql query builder #337

Open
brhenrique opened this Issue Oct 18, 2018 · 1 comment

Comments

2 participants
@brhenrique

brhenrique commented Oct 18, 2018

  • pREST version (or commit ref): v0.3.4
  • pREST endpoint: /DATABASE/SCHEMA/TABLE/?_select
  • PostgreSQL version: 9.4
  • Operating system: linux (amd64)
  • Go version: 1.11
  • Log gist:

Description

_select doesn't seem to be working on v0.3.4

"/testdb/test/user_id?_select=user_id" in v0.3.3 translates to:

[prest] listening on 0.0.0.0:3003 and serving on /
2018/10/18 12:08:57 [debug] tables.go:193 SELECT json_agg(s) FROM (SELECT * FROM "testdb"."test"."user_id" ) s parameters: []

while in v0.3.4 it seems like _select gets completely ignored

[prest] listening on 0.0.0.0:3003 and serving on /
2018/10/18 11:53:33 [debug] tables.go:193 SELECT json_agg(s) FROM "testdb"."test"."user_id" WHERE "user_id" = $1  parameters: [53bf04ec69702d51ca8a0000]

@felipeweb felipeweb added the bug label Oct 18, 2018

@felipeweb

This comment has been minimized.

Member

felipeweb commented Oct 18, 2018

@brhenrique do you want to send a pull request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment