Skip to content

Eager loading user table results in an sql error if the user table has a delete_at field #1307

Open
@nigeltiany

Description

@nigeltiany

What version of SQLBoiler are you using (sqlboiler --version)?

v4.14.2

What is your database and version (eg. Postgresql 10)

Postgres 15

If this happened at runtime what code produced the issue? (if not applicable leave blank)

Eager loading user table results in an sql error if the user table has a delete_at field

Please provide a relevant database schema so we can replicate your issue (Provided you are comfortable sharing this)

a table named user with a deleted_at field and a query that eager loads the users table through a pivot table

Further information. What did you do, what did you expect?

#583

debug log output: SELECT * FROM "user" WHERE ("user"."id" IN ($1)) AND (user.deleted_at is null);
error: failed to eager load User: failed to eager load User: pq: syntax error at or near "."

expected log output: SELECT * FROM "user" WHERE ("user"."id" IN ($1)) AND ("user"."deleted_at" is null);

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions