Dark mode
Relational Database Diagram
แนวคิด: ข้อมูลอยู่ในตารางที่มีความสัมพันธ์กัน (เช่น ลูกค้า 1 คน สั่งซื้อได้หลายครั้ง)
Description: Shows CUSTOMERS
table and ORDERS
table. One customer can have many orders, connected through CustomerID
which is a Primary Key (PK) in the customers table and a Foreign Key (FK) in the orders table.
Document Database Diagram
แนวคิด: ข้อมูลของ "สิ่งหนึ่ง" ถูกเก็บรวมกันในเอกสารเดียว ซึ่งอาจมีโครงสร้างซ้อนกันได้
Description: Shows a single UserProfile
document containing basic information (ID, Name), nested data (Address), and an array of values (Interests) all within the same document.
Key-Value Database Diagram
แนวคิด: เก็บข้อมูลเป็นคู่ Key กับ Value แบบง่ายๆ ตรงไปตรงมา
Description: Shows several key-value pairs where each key directly points to its value. Data access is performed only through the key.
Column-Family Database Diagram
แนวคิด: ข้อมูลจัดกลุ่มตาม "ครอบครัวคอลัมน์" ภายในแถวเดียวกัน แต่ละแถวอาจมีคอลัมน์ไม่เท่ากัน
Description: Shows data for user123
(Row Key) organized into Column Families like Profile
, Clicks_202504
(click data for April 2025), and Purchases_2025
. Note that in the Clicks
family, column names can be timestamps, and each row doesn't need to have data in every family or the same number of columns.
Graph Database Diagram
แนวคิด: เน้นแสดงความสัมพันธ์ (เส้นเชื่อม) ระหว่างข้อมูล (จุด)
Description: Shows various relationships: Alice is friends with Bob, Bob works at ABC Corp, both Alice and Bob have relationships with Product A, and ABC Corp is located in Bangkok.
Time-Series Database Diagram
แนวคิด: ข้อมูลเรียงตามเวลา และมักมี Tag เพื่อระบุแหล่งที่มาหรือประเภท
Description: Shows data arriving in chronological order (T1, T2, T3, T4). Each timestamp has Metric values (such as temperature, humidity, voltage) and Tags providing additional details (such as location, sensor name).
NewSQL Database Diagram
แนวคิด: หน้าตาเหมือน Relational/SQL แต่เบื้องหลังสามารถกระจายตัวเพื่อรองรับข้อมูล/ผู้ใช้จำนวนมากได้
Description: For users or developers, NewSQL looks similar to a traditional Relational Database (using SQL queries, tables, PK/FK relationships), but the key difference is in the backend architecture designed to scale out or distribute data/workload across multiple servers like NoSQL while maintaining ACID properties.
หวังว่า Diagram เหล่านี้จะช่วยให้เห็นภาพแนวคิดของฐานข้อมูลแต่ละประเภทได้ชัดเจนขึ้นนะครับ!