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

CRDB: Handle unicode escaping in enum and string defaults in migrate/introspection #13842

Closed
tomhoule opened this issue Jun 15, 2022 · 0 comments
Assignees
Labels
bug/2-confirmed Bug has been reproduced and confirmed. kind/bug A reported bug. team/schema Issue for team Schema. topic: cockroachdb topic: default
Milestone

Comments

@tomhoule
Copy link
Contributor

This schema is not idempotent, but it should be:

         datasource db {
             provider = "postgres"
             url = "postgres://meowmeowmeow"
         }
 
         enum Color {
             Red @map("0")
             Green @map("Grün")
             Blue @map("Blu")
         }
 
         model Test {
             id Int @id
             mainColor Color @default(Green)
             secondaryColor Color @default(Red)
             colorOrdering Color[] @default([Blue, Red, Green, Red, Blue, Red])
         }
@tomhoule tomhoule added bug/2-confirmed Bug has been reproduced and confirmed. kind/bug A reported bug. topic: cockroachdb topic: default labels Jun 15, 2022
@tomhoule tomhoule self-assigned this Jun 15, 2022
@matthewmueller matthewmueller added the team/schema Issue for team Schema. label Jun 15, 2022
@janpio janpio added this to the 4.0.0 milestone Jun 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug/2-confirmed Bug has been reproduced and confirmed. kind/bug A reported bug. team/schema Issue for team Schema. topic: cockroachdb topic: default
Projects
None yet
Development

No branches or pull requests

3 participants