Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

499
Views
Which is better - Int autoincrement id or cuid for PostgreSQL prisma schema?

We use Postgres and prisma for our Next.js app. Previous developers have used cuid for every table on our schema. For some reasons we are restructuring the tables and I was wondering would it be better to use int ids? Would it result in any performance gain?

What are the tradeoffs between using Int autoincrement id vs cuid for Postgres prisma client?

If you start comparing GUID vs Int ids for Postgres, please quote authentic reference proving that cuid is mapped to guid for Postgres.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

A sequence generating bigint values will certainly be faster than even the most efficient CUID or GUID algorithm, and the result will need less storage space.

The only good reasons to use something else like a CUID or GUID are

  • you have cryptographic requirements to obscure the creation order (but CUID doesn't do that)

  • you need to generate primary keys outside the database and in a distributed environment

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!