Tech TutorBangla Web Documentation
Portfolio
HomeHTMLCSSTailwind CSSJavaScriptTypeScriptReactNext.jsNode.jsExpressSocket.IOExpoWordPressPostgreSQLPrismaPostgresNestJSMongoDBDockerTanStackTanStack TableRTK QueryGitGitHub
  • PrismaPostgres Documentation40টি অধ্যায়
প্রযুক্তি নির্বাচন
HomeHTMLCSSTailwind CSSJavaScriptTypeScriptReactNext.jsNode.jsExpressSocket.IOExpoWordPressPostgreSQLPrismaPostgresNestJSMongoDBDockerTanStackTanStack TableRTK QueryGitGitHub
  • Prisma Intro
  • Prisma vs Raw SQL
  • Setup & Install
  • Schema Basics
  • Models
  • Relations
  • Migrations
  • Prisma Client
  • Create & Upsert
  • Read Queries
  • Update & Delete
  • Query Filters
  • Sort & Pagination
  • Select & Include
  • Nested Writes
  • Transactions
  • Aggregation
  • JSON Fields
  • Raw SQL
  • TechShop Schema
  • TechShop Seed
  • Relations Advanced
  • Env Config
  • Global Client
  • Next.js + Prisma
  • Express API
  • Error Handling
  • Performance
  • Connection Pool
  • Prisma Studio
  • Deploy Migrations
  • TechShop Indexes
  • TechShop Cart
  • TechShop Stats API
  • Schema Evolution
  • Debugging
  • Common Mistakes
  • Best Practices
  • Interview Questions
  • Recap & Next
  1. Docs
  2. PrismaPostgres
  3. select (কয়েকটি ক্ষেত্র) ও include (relation)
PrismaPostgresIntermediate

select (কয়েকটি ক্ষেত্র) ও include (relation)

রেস্টrict ফেরত — connection join-er control।

4টি অংশবাংলা ভাষায়
select — শুধু দরকারি fieldsts
ts
const users = await prisma.user.findMany({
  where: { active: true },
  select: { id: true, email: true, name: true },
});
include — relation কে সাথেts
ts
const orders = await prisma.order.findMany({
  where: { status: "pending" },
  include: {
    items: { include: { product: true } },
    user: { select: { name: true, email: true } },
  },
});

select পেলে result-এর shape ঠিক ততটাই টাইপ — nesting level indefinite (Prisma 5-এ depth পর্যন্ত)। include — relation field যোগ।

N+1 গুজব

Prisma-র include এক query-তে relation fetch — app-কোডে loop-এ findMany call নয়। (raw SQL-তে JOIN আরও সরাসরি — দুটোই জানা ভালো।)

শেষ প্যারায় নিজে practice করুন — কোড কপি করে নিজের এডিটরে চালিয়ে দেখুন।
আগেরorderBy, take/skip, cursorপরেরNested write — বাবা-সন্তান এক query-তে
Tech Tutor

বাংলায় ওয়েব ডেভেলপমেন্ট ডকুমেন্টেশন শিখুন — ধাপে ধাপে।

Homeসব ডকুমেন্টেশনQuick Startআমার নোটস

© 2026 Tech Tutor. বাংলায় শিখুন, বাংলায় গড়ুন।

mdanamolhasan1998@gmail.com