Joe
Joe
DTDrizzle Team
Created by Joe on 1/31/2025 in #help
Error: There are multiple relations between "__public__.*" and "*". Please specify relation name
is the relation supposed to reference one side or something different to avoid clash?
5 replies
DTDrizzle Team
Created by Joe on 1/31/2025 in #help
Error: There are multiple relations between "__public__.*" and "*". Please specify relation name
export const userRelations = relations(user, ({ many }) => ({ sessions: many(gameSession), createdDecks: many(deck), playerStates: many(playerState), activeGames: many(gameSession, { relationName: 'activePlayer' }), wonGames: many(gameSession, { relationName: 'winner' }), })); export const gameSessionRelations = relations(gameSession, ({ one, many }) => ({ game: one(game, { fields: [gameSession.gameId], references: [game.id], }), deck: one(deck, { fields: [gameSession.deckId], references: [deck.id], }), currentPhase: one(phase, { fields: [gameSession.currentPhaseId], references: [phase.id], }), activePlayer: one(user, { fields: [gameSession.activePlayerId], references: [user.id], relationName: 'activePlayer' }), winner: one(user, { fields: [gameSession.winnerId], references: [user.id], relationName: 'winner' }), playerStates: many(playerState), actions: many(gameAction), events: many(gameEvent), })); Error: There are multiple relations between "public.gameSession" and "user". Please specify relation name
5 replies
DTDrizzle Team
Created by Joe on 9/4/2023 in #help
drizzle-kit generate requires sudo to create directory and SyntaxError on index.cjs, Unexpected "?"
Ahhh i see, I have a feeling it could be to do with Bun's module resolution - i will re-read the docs and try again. Will send a repo link if i have no success, thanks!
3 replies