diff --git a/prisma/migrations/20241212122823_rename_prices_paid_table_and_columns/migration.sql b/prisma/migrations/20241212122823_rename_prices_paid_table_and_columns/migration.sql new file mode 100644 index 0000000..831d9d2 --- /dev/null +++ b/prisma/migrations/20241212122823_rename_prices_paid_table_and_columns/migration.sql @@ -0,0 +1,6 @@ +-- Alter table +ALTER TABLE "pricespaid" RENAME TO "prices_paid"; + +-- Alter table +ALTER TABLE "prices_paid" RENAME COLUMN "propertytype" TO "property_type"; +ALTER TABLE "prices_paid" RENAME COLUMN "transactionidentifier" TO "transaction_identifier"; \ No newline at end of file diff --git a/prisma/migrations/20241212123044_rename_prices_paid_constraint/migration.sql b/prisma/migrations/20241212123044_rename_prices_paid_constraint/migration.sql new file mode 100644 index 0000000..0be686b --- /dev/null +++ b/prisma/migrations/20241212123044_rename_prices_paid_constraint/migration.sql @@ -0,0 +1,2 @@ +-- AlterTable +ALTER TABLE "prices_paid" RENAME CONSTRAINT "pricespaid_pkey" TO "prices_paid_pkey"; diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 86e4c55..80b5d65 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -50,13 +50,13 @@ model ItlLookup { model PricesPaid { id Int @id @default(autoincrement()) - transactionIdentifier String? @map("transactionidentifier") @db.VarChar(250) + transactionIdentifier String? @map("transaction_identifier") @db.VarChar(250) price Float? postcode String? @db.VarChar(250) - propertyType String? @map("propertytype") @db.VarChar(250) + propertyType String? @map("property_type") @db.VarChar(250) newBuild String? @map("newbuild") @db.VarChar(250) - @@map("pricespaid") + @@map("prices_paid") } model Rent {