Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prisma Parser - Support @@map #557

Open
MH4GF opened this issue Jan 24, 2025 · 0 comments
Open

Prisma Parser - Support @@map #557

MH4GF opened this issue Jan 24, 2025 · 0 comments
Labels

Comments

@MH4GF
Copy link
Member

MH4GF commented Jan 24, 2025

Task description

Since the model name and the actual table name can be set separately, it is necessary to support them.
For ERD tools, we want to use properties that match the real table.

model Comment {
  // Fields

  @@map(“comments”)
}

https://www.prisma.io/docs/orm/prisma-schema/data-model/models#mapping-model-names-to-tables-or-collections

I think I can get it with model.dbName in DMMF, but I haven't checked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant