Skip to content

Multiple tuple where clause #104

@blockloop

Description

@blockloop

I'm trying to recreate this query with squirrel:

SELECT id, name
FROM users
WHERE ((name, age)) IN (('Alex', 10), ('Douglas', 40))

The closest I can come up with is this and it's wrong:

query := sq.Select("id, name").
	From("users").
	Where(sq.Eq{
		"((id, name))": []string{"('Alex', 10)", "('Douglas', 40)"},
	})

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions