Skip to content

Generated relationships does not have a G variant #87

Closed
@eduacostam

Description

@eduacostam

When setting up sqlboiler using boil.SetDB(db) we can use global variants of methods for accessing data instead of passing a *sql.DB pointer around. Generated relationships between models do not have a global variant.

What I would expect is that for each AddX, SetX, RemoveX there would be a G variant AddXG, SetXG, RemvoeXG.

As it is I started using the G variants to avoid passing an *sql.DB instance to all my structs, but in order to use relationships the struct must have knowledge of the DB object anyway.

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