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

How to differentiate 'AND' vs 'OR #56

Open
tai-pd opened this issue Jan 17, 2020 · 1 comment
Open

How to differentiate 'AND' vs 'OR #56

tai-pd opened this issue Jan 17, 2020 · 1 comment

Comments

@tai-pd
Copy link

tai-pd commented Jan 17, 2020

  • I see json when query : OR, AND in "conds" just a array of condition and separate by sysbol ",",
    So what a signature maked we know that is "AND" or "OR" ?
@CrafterKolyan
Copy link

Due to

WikiSQL/lib/query.py

Lines 46 to 47 in 7080c89

if self.conditions:
rep += ' WHERE ' + ' AND '.join(['{} {} {}'.format('col{}'.format(i), self.cond_ops[o], v) for i, o, v in self.conditions])

it's always "AND"

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