惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Security Archives - TechRepublic
C
Cyber Attacks, Cyber Crime and Cyber Security
P
Proofpoint News Feed
Cisco Talos Blog
Cisco Talos Blog
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
CERT Recently Published Vulnerability Notes
S
Secure Thoughts
H
Hacker News: Front Page
I
Intezer
Cyberwarzone
Cyberwarzone
T
Tor Project blog
The Last Watchdog
The Last Watchdog
Google DeepMind News
Google DeepMind News
T
Threatpost
T
Tenable Blog
NISL@THU
NISL@THU
AWS News Blog
AWS News Blog
阮一峰的网络日志
阮一峰的网络日志
T
Troy Hunt's Blog
E
Exploit-DB.com RSS Feed
V
Visual Studio Blog
W
WeLiveSecurity
腾讯CDC
The GitHub Blog
The GitHub Blog
T
The Exploit Database - CXSecurity.com
Engineering at Meta
Engineering at Meta
H
Hackread – Cybersecurity News, Data Breaches, AI and More
V
V2EX - 技术
A
Arctic Wolf
N
Netflix TechBlog - Medium
S
Securelist
WordPress大学
WordPress大学
Schneier on Security
Schneier on Security
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Vercel News
Vercel News
Recent Commits to openclaw:main
Recent Commits to openclaw:main
AI
AI
N
News | PayPal Newsroom
T
The Blog of Author Tim Ferriss
B
Blog
Apple Machine Learning Research
Apple Machine Learning Research
Help Net Security
Help Net Security
Google Online Security Blog
Google Online Security Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
G
Google Developers Blog
小众软件
小众软件
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Cloudbric
Cloudbric
P
Palo Alto Networks Blog

SQLite

SQLite 开启 WAL 后,我的同步服务吞吐量提升了 3 倍 分享适合高并发场景的 SQLite 设置 - V2EX 在什么情况下一定要放弃 SQLite 采用 MySQL 呢? - V2EX SQLite 背后的故事 - V2EX 应该怎么理解 rowid 在 sqlite 中的使用 - V2EX macOS 上有什么好用的 SQLite GUI ? - V2EX SQLite In-Memory 作为数据缓存代替 Java Object - V2EX 什么时候调用 sqlite.close()呢 - V2EX 回复“什么场景下用 SQLite”的主题并分享一个年收入 60 万刀的技术栈 - V2EX 大家有用 Sqlite 的吗,都是什么场景下要用这个,能说一两点非要用它的理由最好啦 SQLite Viewer Web App - V2EX 本地数据库 除了 SQLite 还有什么好用的. - V2EX 请教一个方案,边缘设备的 sqlite 数据如何才能获取到 - V2EX 有人知道怎么在 termux 上编译 sqlcipher 吗? SQLite 被曝漏洞,影响范围很大 两个读写 SQLite 数据库的浏览器扩展 How SQLite is tested 如果需要寫入數據, 不僅數據文件要有寫入權限, 數據文件所在的目錄也要有寫入權限 用sqlite3作为论坛的数据库行不行? About Sqlite 之前的一篇笔记 如何把一个2G的sqlite数据库分割成小的? Base 2.0
求一个数据库设计问题! - V2EX
Iamnotfish · 2019-08-03 · via SQLite

| Department | Sub-department | Category | Unit |
| ---------- | -------------- | -------- | -------- |
| Id | Id | Id | Id |
| Name | Name | Name | Name |
| Position | Position | Position | Position |
| Active | | | |

一共四张表,关系从左至右都是一对多。现在我问题是如果我添加外键用来链表的话,unit 这张最小的表的数据量将会非常大而且很多都是重复的。四张表的具体数据如下:
Department | Id | Name(STR) | Position(INT) | Active(INT) |
| ---- | --------- | ------------- | ----------- |
| 1 | AAA | 1 | 0 |
| 2 | BBB | 2 | 0 |
| 3 | CCC | 3 | 1 |
| 4 | DDD | 4 | 1 |

Sub-department
| Id | Name(STR) | Position(INT) |
| ---- | --------- | ------------- |
| 1 | AAA | 1 |
| 2 | BBB | 2 |
| 3 | CCC | 3 |
| 4 | DDD | 4 |

Category
| Id | Name(STR) | Position(INT) |
| ---- | --------- | ------------- |
| 1 | AAA | 1 |
| 2 | BBB | 2 |
| 3 | CCC | 3 |
| 4 | DDD | 4 |

Unit
| Id | Name(STR) | Position(INT) |
| ---- | --------- | ------------- |
| 1 | AAA | 1 |
| 2 | BBB | 2 |
| 3 | CCC | 3 |
| 4 | DDD | 4 |

请问一下我该怎么修改我的表的结构避免重复数据产生呢?

补充一下!具体的业务是类似于路径查找那样的,点开我的电脑然后显出出来所有的在我的电脑下的文件夹,然后选择不同的文件夹进入里面在进入到子文件夹这样。