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

Simplify multiple `AND` `OR` sql generation #300

Closed
jilen opened this Issue Mar 23, 2016 · 0 comments

Comments

Projects
None yet
2 participants
@jilen
Collaborator

jilen commented Mar 23, 2016

Version: 0.5.1-SNAPSHOT
Module: quill-sql

Expected behavior

If we filter on multi condition such as

query[Order].filter(_.user_id == xxx).filter(_.cat = xxx).filter(_.date = xxx)

The generated sql should be as simple as

(x_7.`user_id` = ? AND x_7.`cat` = ? AND x_7.`date` = ?)

Actual behavior

((x_7.`user_id` = ?) AND (x_7.`cat` = ?)) AND (x_7.`date` = ?)) 

The generated sql is in a nested structure

Steps to reproduce the behavior

Described above
@getquill/maintainers

@jilen jilen added the enhancement label Mar 23, 2016

@fwbrasil fwbrasil added the easy label Apr 19, 2016

@juliano juliano referenced this issue Dec 23, 2017

Merged

Simplify multiple `AND` `OR` sql generation #1003

5 of 5 tasks complete

@mentegy mentegy closed this in #1003 Jan 2, 2018

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