Skip to content

Logical Upsert example does not work #26

@MB175

Description

@MB175

https://fenos.github.io/dqlx/docs/mutations/set

The example has a dot to much and does not work since the type does not fit

data := []map[string]interface{}{
    {
        "uid": "uid(v)",
        "email": "user@company1.io",
        "name": "first name"
    },
}

userByEmailQuery := dqlx.Query(dqlx.EqFn("email", "user@company1.io")).  
    .Select(` // There shouldn't be a Dot here
        v as uid
        name
    `)

resp, err := db.Mutation().
    Query(userByEmailQuery).  // Type does not implement 'DQLizer'
    Set(data).
    Execute(ctx)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions