Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

docs(database-docs): align zh-CN labels and explain notes file

dienaso9177568655df
diff --git a/docs/content/docs/database-docs.cn.mdx b/docs/content/docs/database-docs.cn.mdx
index 61e854f3e2..71e35d6c19 100644
--- a/docs/content/docs/database-docs.cn.mdx
+++ b/docs/content/docs/database-docs.cn.mdx
@@ -9,9 +9,9 @@ description: 以文档方式浏览 Schema,为表和字段编写笔记并按颜
## 打开方式
-在[对象浏览器](/cn/docs/object-browser)中右键点击一张表,选择 **Documentation**。查看器会基于当前连接、数据库和 Schema 打开。
+在[对象浏览器](/cn/docs/object-browser)中右键点击一张表,选择 **文档**。查看器会基于当前连接、数据库和 Schema 打开。
-侧边栏可在 **Schemas** 和 **Table Groups** 之间切换。搜索会同时覆盖表、字段和分组。每个表页面列出字段、索引、**References** 与 **Referenced by**,因此关系可以双向查看。
+侧边栏可在 **Schema** 和 **表分组** 之间切换。搜索会同时覆盖表、字段和分组。每个表页面列出字段、索引、**引用** 与 **被引用**,因此关系可以双向查看。
## 笔记与分组
@@ -22,19 +22,19 @@ description: 以文档方式浏览 Schema,为表和字段编写笔记并按颜
| 字段笔记 | 表格中的字段行 |
| 表分组及其颜色 | 表页面的分组选择器 |
-笔记支持 Markdown,并在索引中内联渲染。每次编辑都会自动保存,标题栏会依次显示 **Saving…** 和 **Saved**。写入失败会被明确提示而不是被吞掉,你的文字会保留下来,下一次编辑时重试。
+笔记支持 Markdown,并在索引中内联渲染。每次编辑都会自动保存,标题栏会依次显示 **保存中…** 和 **已保存**。写入失败会被明确提示而不是被吞掉,你的文字会保留下来,下一次编辑时重试。
分组保存的是**色相(hue)**,而不是固定颜色。明度和彩度由当前主题决定,因此同一个分组在浅色和深色模式下都保持清晰可读;导出 DBML 时,这个色相会转换成 `[color: #rrggbb]`。
## 本地笔记与数据库注释
-如果某个字段既有数据库的 `COMMENT ON`,又有你在 DBX 中写的笔记,页面会显示你的笔记并标记 **LOCAL**,同时在下方保留原有的数据库注释。数据库中的内容不会被覆盖——DBX 从不为文档执行 DDL,原始注释始终可以找回。
+如果某个字段既有数据库的 `COMMENT ON`,又有你在 DBX 中写的笔记,页面会显示你的笔记并标记 **本地**,同时在下方保留原有的数据库注释。数据库中的内容不会被覆盖——DBX 从不为文档执行 DDL,原始注释始终可以找回。
## 笔记的存储位置
默认情况下,每个连接在 DBX 数据目录中拥有各自的笔记文件,因此该功能开箱即用。
-你也可以在连接的**高级**设置中填写 **Notes file**(对应配置项 `docs_notes_path`),把它指向仓库中的文件。笔记文件的结构如下:
+你也可以在连接的**高级**设置中填写**笔记文件**(英文界面为 **Notes file**,配置项 `docs_notes_path`),把它指向仓库中的文件。笔记文件的结构如下:
```json
{
diff --git a/docs/content/docs/faq.cn.mdx b/docs/content/docs/faq.cn.mdx
index 883a6155b7..a5d140772b 100644
--- a/docs/content/docs/faq.cn.mdx
+++ b/docs/content/docs/faq.cn.mdx
@@ -1,6 +1,6 @@
---
title: 常见问题
-description: DBX 常见问题:连接数据保存在哪里、如何备份、如何让数据与程序同目录或自定义数据目录。
+description: DBX 常见问题:连接数据保存在哪里、如何备份、如何让数据与程序同目录或自定义数据目录,以及连接设置中「笔记文件」的用途。
---
<Callout type="info">DBX 桌面端的常见问题。本页从数据存储与数据目录开始,后续会持续补充新条目。</Callout>
@@ -62,3 +62,13 @@ clientEncoding=GB18030&serverEncoding=ISO-8859-1
这组参数只适用于数据库声明编码与实际文本字节不一致的连接。服务端必须报告 `server_encoding=LATIN1`,且 `standard_conforming_strings=on`。读取遇到无法转换的值时保留原文,并在查询消息中提示;其他完整的文本仍正常解码。按字节截断的脱敏值(例如半个汉字后接星号)不会再导致整条查询失败,也不会被替换字符或 NULL 覆盖。写入时不能用指定编码表示的内容仍明确报错。未填写参数的连接使用正常的 PostgreSQL 编码转换。
COPY 文本导入支持 DBX 的默认文本格式;跨连接数据传输会使用按行 INSERT 路径。原始 COPY 输出和其他 COPY 格式请使用按行导入/导出。
+
+## 连接设置里的「笔记文件」是什么?
+
+**笔记文件**(英文界面为 **Notes file**,配置项 `docs_notes_path`)是[数据库文档](/cn/docs/database-docs)功能保存笔记的位置,在编辑连接的**高级**设置中填写。
+
+- 留空时,笔记保存在 DBX 应用数据目录中,每个连接各一份,开箱即用。
+- 指向仓库中的文件(例如 `docs/dbx-docs.json`)后,表和字段的笔记可以随代码提交,让 Schema 文档在 Pull Request 中被评审。
+- 笔记本身在对象浏览器中右键表选择**文档**打开的查看器里编写,支持 Markdown 和分组颜色,自动保存;AI 助手也会读取这份文件,把笔记作为对应表/字段的说明。
+
+文件结构、警告行为和 DBML 导出见 [数据库文档](/cn/docs/database-docs)。
diff --git a/docs/content/docs/faq.mdx b/docs/content/docs/faq.mdx
index 3ee7b05bca..9b78ce5028 100644
--- a/docs/content/docs/faq.mdx
+++ b/docs/content/docs/faq.mdx
@@ -1,6 +1,6 @@
---
title: FAQ
-description: Frequently asked questions about DBX, including where connection data is stored and how to customize the data directory.
+description: Frequently asked questions about DBX, including where connection data is stored, how to customize the data directory, and what the notes file connection setting is for.
---
<Callout type="info">Common questions about DBX Desktop. This page starts with data storage and the data directory, and more entries will be added over time.</Callout>
@@ -62,3 +62,13 @@ Save and reconnect. The native driver converts query results, SQL and bound para
Use these parameters only when the declared database encoding differs from its text bytes. The server must report `server_encoding=LATIN1` and `standard_conforming_strings=on`. On reads, values that cannot be converted retain their original text and produce a query warning; valid values still decode normally. Byte-truncated masked values, such as half a multibyte character followed by asterisks, do not abort the whole query and are never replaced with NULL or replacement characters. Writes still reject characters that the selected encoding cannot represent. Connections without these parameters use normal PostgreSQL encoding conversion.
COPY imports support DBX's default text format; transfers use the row-based INSERT path. Use row-based import/export for raw COPY output or other COPY formats.
+
+## What is the "Notes file" connection setting?
+
+The **Notes file** setting (config key `docs_notes_path`) is where the [Database documentation](/en/docs/database-docs) feature stores its notes. You'll find it in the **Advanced** section of the connection form.
+
+- Leave it empty and notes live in the DBX app data directory, one file per connection, with no setup.
+- Point it at a file in your repository (for example `docs/dbx-docs.json`) to commit table and column notes with your code and review schema documentation in pull requests.
+- The notes themselves are written in the viewer that opens when you right-click a table in the object browser and choose **Documentation**. They support Markdown and colour-coded groups, autosave, and the AI assistant reads the same file as descriptions for the matching tables and columns.
+
+See [Database documentation](/en/docs/database-docs) for the file format, warning behaviour, and DBML export.