Skip to content

Commit f043b6b

Browse files
authored
chore: update cwgo model (cloudwego#848)
Signed-off-by: rogerogers <[email protected]>
1 parent 804f238 commit f043b6b

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

content/en/docs/cwgo/tutorials/db/_index.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ OPTIONS:
2929
--out_dir value Specify output directory (default: biz/dao/query)
3030
--out_file value Specify output filename (default: gen.go)
3131
--tables value [ --tables value ] Specify databases tables
32+
--exclude_tables value [ --exclude_tables value ] Specify exclude tables
3233
--unittest Specify generate unit test (default: false)
3334
--only_model Specify only generate model code (default: false)
3435
--model_pkg value Specify model package name
@@ -39,6 +40,8 @@ OPTIONS:
3940
--help, -h show help (default: false)
4041
```
4142

43+
> All tables in the SQLite database that **start with sqlite** will be ignored, such as sqlite_sequence and sqlite_master.
44+
4245
## Specification
4346

4447
```console
@@ -47,6 +50,7 @@ OPTIONS:
4750
--out_dir value specifies the output directory path, the default is biz/dao/query
4851
--out_file value specify the output file name, the default is gen.go
4952
--tables value specifies the database table, the default is the full table
53+
--exclude_tables value [ --exclude_tables value ] Specify exclude tables, the default is empty
5054
--unittest specifies whether to generate unit tests, the default is false
5155
--only_model specifies whether to generate only model, default is false
5256
--model_pkg value specifies the package name of the model

content/zh/docs/cwgo/tutorials/db/_index.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ OPTIONS:
2929
--out_dir value Specify output directory (default: biz/dao/query)
3030
--out_file value Specify output filename (default: gen.go)
3131
--tables value [ --tables value ] Specify databases tables
32+
--exclude_tables value [ --exclude_tables value ] Specify exclude tables
3233
--unittest Specify generate unit test (default: false)
3334
--only_model Specify only generate model code (default: false)
3435
--model_pkg value Specify model package name
@@ -39,6 +40,8 @@ OPTIONS:
3940
--help, -h show help (default: false)
4041
```
4142

43+
> 会忽略 sqlite 数据库所有 **sqlite 开头**的表,比如 sqlite_sequence、sqlite_master
44+
4245
## 详细参数
4346

4447
```console
@@ -47,6 +50,7 @@ OPTIONS:
4750
--out_dir value 指定输出目录路径,默认为 biz/dao/query
4851
--out_file value 指定输出文件名,默认为 gen.go
4952
--tables value 指定数据库表,默认为全表
53+
--exclude_tables value [ --exclude_tables value ] 指定排除的表,默认为空
5054
--unittest 指定是否生成单测,默认为 false
5155
--only_model 指定是否生成仅 model,默认为 false
5256
--model_pkg value 指定 model 的包名

0 commit comments

Comments
 (0)