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

@db.VarChar(14): maxlength info is lost #781

Open
xiangnanscu opened this issue Nov 7, 2022 · 2 comments
Open

@db.VarChar(14): maxlength info is lost #781

xiangnanscu opened this issue Nov 7, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@xiangnanscu
Copy link

for example

dwmc     String?   @default("") @db.VarChar(50)

only output as

        "dwmc": {
          "type": [
            "string",
            "null"
          ],
          "default": ""
        },

is this a feature or a bug?

@valentinpalkovic
Copy link
Owner

It is a feature. Is @db.VarChar the only field scalar type we have to consider?

@valentinpalkovic valentinpalkovic added the enhancement New feature or request label Jan 20, 2023
@benvd
Copy link

benvd commented Feb 24, 2023

I found this issue when trying to get "format": "uuid" added to the JSON schema for columns with @db.Uuid. Turns out this information isn't part of the DMMF, so I don't think a type generator can solve this without engine support.

There's a pull request about this: prisma/prisma-engines#2660

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

No branches or pull requests

3 participants