text: /*
    Warnings:
  
    - Added the required column `ownerId` to the `Hub` table without a default value. This is not possible if the table is not empty.
  
  */
  -- AlterTable
  ALTER TABLE "Hub" ADD COLUMN     "ownerId" INTEGER NOT NULL;
  
  -- CreateTable
  CREATE TABLE "Reservation" (
      "id" SERIAL NOT NULL,
      "checkInDate" TIMESTAMP(3) NOT NULL,
      "checkOutDate" TIMESTAMP(3) NOT NULL,
      "notes" TEXT,
      "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
      "updateddAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
      "hubId" INTEGER NOT NULL,
      "ownerId" INTEGER NOT NULL,
  
      CONSTRAINT "Reservation_pkey" PRIMARY KEY ("id")
  );
  
  -- AddForeignKey
  ALTER TABLE "Hub" ADD CONSTRAINT "Hub_ownerId_fkey" FOREIGN KEY ("ownerId") REFERENCES "User"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
  
  -- AddForeignKey
  ALTER TABLE "Reservation" ADD CONSTRAINT "Reservation_hubId_fkey" FOREIGN KEY ("hubId") REFERENCES "Hub"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
  
  -- AddForeignKey
  ALTER TABLE "Reservation" ADD CONSTRAINT "Reservation_ownerId_fkey" FOREIGN KEY ("ownerId") REFERENCES "User"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
  