refactor
optimize: zero and one
sql test
Improve query generation
improve query build logic
add test
add test
refactor
left inner join
add tests