Relationships not working? (Simplest one-one relationship)

I can't seem to have Drizzle return the correct query when using the relationship syntax. I have the following relationship defined:
user-schema.ts
export const manager = mysqlTable('manager', {
    userId: varchar('user_id', { length: 36 }).notNull().references(() => user.id, { onDelete: 'cascade' }),
});

auth-schema.ts
export const user = mysqlTable('user', {
    id: varchar('id', { length: 36 }).primaryKey(),

relationship-schema.ts
export const userRelations = relations(user, ({ one }) => ({
    manager: one(manager, {
        fields: [user.id],
        references: [manager.userId],
    }),
}));

but however when I query:
await db.query.user.findMany({
            with: {
                manager: true,
            },
        });

It returns users with no managers associated. Am I doing something wrong here? First time using drizzle!
Tysm ❤️
Was this page helpful?