နားလည်ထားရမယ့် အချက်
Technology တစ်ခုချင်းစီရဲ့ အသေးစိတ်ကနေ ခဏတန်း ရှောင်ထွက်ပြီး database အဓိကတွေက landscape တစ်ခုလုံးမှာ ဘယ်နေရာ ရှိလဲ ကြည့်ကြည့်ရအောင်။
PostgreSQL နှင့် MySQL နှစ်ခုစလုံးက general-purpose relational database တွေဖြစ်ပါတယ်။ ဒီ site မှာ PostgreSQL course ရှိပေမယ့် MySQL မှာ မရှိသေးပါ - ဒါပေမယ့် role တူတူပါပဲ။ ဘယ်တစ်ခုမှ universal winner မဟုတ်ပါ။
SQLite ကတော့ embedded, file-based relational database တစ်ခုပါ - network server မဟုတ်ပါ။ နောက်သင်ခန်းစာမှာ ပိုနက်ရှိုင်းစွာ လေ့လာမှာပါ။
MongoDB က document-database ချဉ်းကပ်နည်းကို၊ Redis က key-value/caching ချဉ်းကပ်နည်းကို ကိုယ်စားပြုပါတယ် - နှစ်ခုစလုံးကို ဒီ site ရဲ့ course သီးသန့်တွေမှာ နက်ရှိုင်းစွာ ဖော်ပြထားပါတယ်။
Supabase Database က PostgreSQL အပေါ် တည်ဆောက်ထားတဲ့ managed platform ဖြစ်ပြီး၊ လက်တွေ့ အနက်ရှိုင်းစွာကတော့ "Cloud Providers & Platforms" course ရဲ့ Supabase သင်ခန်းစာမှာသာ ရှိပါတယ်။
| System | အခန်းကဏ္ဍ |
|---|---|
| PostgreSQL | General-purpose relational database, ကိုယ်ပိုင် course ရှိတယ် - PostgreSQL course ကို ဆက်လေ့လာပါ |
| MySQL | General-purpose relational database, PostgreSQL နှင့် role ဆင်တူတယ်, ဒီ site မှာ course သီးသန့် မရှိသေးပါ |
| SQLite | Embedded, file-based relational database - နောက်သင်ခန်းစာမှာ ဆက်လေ့လာပါ |
| MongoDB | Document database - MongoDB course ကို ဆက်လေ့လာပါ |
| Redis | Key-value store / cache - Redis course ကို ဆက်လေ့လာပါ |
| Supabase Database | Managed PostgreSQL + auth/storage/API - Cloud Providers & Platforms course ရဲ့ Supabase သင်ခန်းစာကို ဆက်လေ့လာပါ |
DATABASE SYSTEMS LANDSCAPE
--------------------------
RELATIONAL DOCUMENT KEY-VALUE
PostgreSQL, MySQL MongoDB Redis
(server, general use) (flexible docs) (cache, fast lookups)
SQLite
(embedded, single-file, no server process)
MANAGED PLATFORM
Supabase Database (managed PostgreSQL + auth, storage, APIs)လက်တွေ့ scenario နဲ့ ချိတ်ကြည့်မယ်
General-purpose relational database လိုအပ်လား? PostgreSQL (ဒါမှမဟုတ် MySQL) က default အနေနှင့် ဘေးကင်းပါတယ်။ Server မလိုအပ်ဘဲ app ကိုယ်တိုင် ပါလာမယ့် database လိုအပ်လား? SQLite ကတော့ ဒီအခန်းကဏ္ဍအတွက် ကိုက်ညီပါတယ်။
Rigid table ထဲ မကိုက်ညီတဲ့ content ကို သိမ်းဖို့ လိုအပ်ရင် MongoDB ကို ကြည့်ပါ။ Session/cache/leaderboard အတွက် အလွန်မြန်တဲ့ lookup လိုအပ်ရင် Redis ကတော့ အဲဒီအလုပ်အတွက်ပါ။
Infrastructure work ကို ကျော်ဖြတ်ချင်ပြီး authentication/instant API ပါတဲ့ managed Postgres လိုအပ်ရင် Supabase Database ကို ဆန်းစစ်ကြည့်ပါ။
အောက်က runnable ဥပမာက ဒီ checklist ကို function ငယ်လေးတစ်ခုအဖြစ် ပြောင်းထားပါတယ်။
အတူတူ စမ်းရေးကြည့်မယ်
function suggestSystem(need) {
const map = {
"general web app relational data":
"PostgreSQL (or MySQL) - general-purpose relational database. Continue: the PostgreSQL course.",
"embedded mobile app storage":
"SQLite - embedded, file-based database. Continue: this course's SQLite lesson.",
"flexible document data":
"MongoDB - document database. Continue: the MongoDB course.",
"fast cache/session store":
"Redis - key-value store. Continue: the Redis course.",
"managed Postgres with built-in auth":
"Supabase Database - managed PostgreSQL plus extras. Continue: the Supabase lesson in Cloud Providers & Platforms.",
};
return map[need] || "Not on this map yet - describe the need more specifically.";
}
[
"general web app relational data",
"embedded mobile app storage",
"flexible document data",
"fast cache/session store",
"managed Postgres with built-in auth",
].forEach((need) => console.log(`${need} ->`, suggestSystem(need)));general web app relational data -> PostgreSQL (or MySQL) - general-purpose relational database. Continue: the PostgreSQL course.
embedded mobile app storage -> SQLite - embedded, file-based database. Continue: this course's SQLite lesson.
flexible document data -> MongoDB - document database. Continue: the MongoDB course.
fast cache/session store -> Redis - key-value store. Continue: the Redis course.
managed Postgres with built-in auth -> Supabase Database - managed PostgreSQL plus extras. Continue: the Supabase lesson in Cloud Providers & Platforms.
Need key 5 ခုစလုံးက landscape ထဲက system တစ်ခုစီနှင့် ဆက်လက် ကြည့်ရမည့် course သို့ ကိုက်ညီစွာ map လုပ်ထားပါတယ်။၅ မိနစ် စမ်းကြည့်
suggestSystem ရဲ့ map object ထဲ "graph-shaped relationships (social network)" ဆိုတဲ့ key အသစ်တစ်ခု ထည့်ပြီး graph database တစ်ခုကို အကြံပြုပါ။
သတိလေးတစ်ချက်
PostgreSQL/MySQL ကို "တစ်ခုက တစ်ခုထက် အမြဲပိုကောင်း" ဟု winner ရွေးပြီး ပြောခြင်း
Supabase Database ကို PostgreSQL နှင့် လုံးဝဆက်စပ်မှုမရှိတဲ့ သီးခြား product တစ်ခုအဖြစ် ထင်ခြင်း
Wikipedia: Comparison of relational database management systems — How Databases Work