- install packages
npm i
- Populate
DATABASE_URL
in.env
file with a planetscale DB URL - Run
npx prisma db push
to apply schema to the database (id
,name
,lastname
) - Add a new Column to the
Person
model (exampleage Int
) - run
npx prisma generate
(we do not want to add the new column to the database to generate the error) - remove the comment on line 9 in
index.ts
to add theage
column to the payload - run the script
ts-node index.ts
- receive an error with
meta: { column: '(not available)' }
you can apply the same steps with a non-planetscale database, you will recieve an error but it will specify that the column is `age`