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

query/create-h-sql-where-vector incompatible with PSQL #17

Open
owengalenjones opened this issue Sep 7, 2015 · 2 comments
Open

query/create-h-sql-where-vector incompatible with PSQL #17

owengalenjones opened this issue Sep 7, 2015 · 2 comments
Assignees

Comments

@owengalenjones
Copy link

Calling str on something like {:id 4} will result in:

com.rjmetrics.sweet-liberty.db {"raw-query":["SELECT email, id FROM users WHERE id = ?","1"]}

Which throws an error in PSQL, it's not as forgiving as MySQL:

ERROR:  operator does not exist: integer = character varying at character 38
HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.
@owengalenjones owengalenjones self-assigned this Sep 8, 2015
@awm33
Copy link

awm33 commented Sep 2, 2016

Just ran into this trying to use postgres behind a new service. Looks like sweet-lib forces everything to be a string https://github.com/RJMetrics/sweet-liberty/blob/master/src/com/rjmetrics/sweet_liberty/query.clj#L42

@awm33
Copy link

awm33 commented Sep 2, 2016

Is there reasoning for doing that? url-params could be parsed before being passed, query-params would be more difficult.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants