Hello <@U023X2ZV0PR>, I'm not sure if this is the ...
# orm-help
d
Hello @Jesús Quirós, I'm not sure if this is the problem but could you try using the
uuid()
function inside of the
@default()
. Maybe that can be causing prisma to regenerate something or to reload data in some way. Because its trying to create new uuids
j
Hi @Daniel Olavio Ferreira, sorry for the late response. So I tried the following model:
Copy code
model Test2 {
  id  String  @id @default(uuid()) @db.Uuid
  name  String

}
This is what Prisma generated:
Copy code
CREATE TABLE "Test2" (
    "id" UUID NOT NULL,
    "name" TEXT NOT NULL,

    PRIMARY KEY ("id")
);
So no default value when including the uuid() function.
d
So it is still generating the same query every migration that you create? is that right?