Simplified creation of operator expression.
This commit is contained in:
parent
a2fbc4f53a
commit
57aa62f483
6 changed files with 75 additions and 102 deletions
|
|
@ -27,6 +27,20 @@ func TestExists(t *testing.T) {
|
|||
FROM db.table2
|
||||
WHERE table1.col1 = table2.col3
|
||||
))`, int64(1))
|
||||
|
||||
assertSerialize(t, EXISTS(
|
||||
SELECT(Int(1)),
|
||||
).EQ(Bool(true)),
|
||||
`((EXISTS (
|
||||
SELECT $1
|
||||
)) = $2)`, int64(1), true)
|
||||
|
||||
assertProjectionSerialize(t, EXISTS(
|
||||
SELECT(Int(1)),
|
||||
).AS("exists"),
|
||||
`(EXISTS (
|
||||
SELECT $1
|
||||
)) AS "exists"`, int64(1))
|
||||
}
|
||||
|
||||
func TestIN(t *testing.T) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue