You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When filtering tables in the input schema with include in .tbls.yml, the er.showColumnTypes.related/primary setting to hide columns other than PK and FK in the ER diagram output no longer works.
When I wrote all tables in the input schema in the include (even with wildcards), the problem did not occur.
What you expected to happened
I expect that even if include is set, columns other than PK and FK will be hidden in the same way as if it were not set.
What stack trace or error message from tbls did you see?
Anything else we need to know?
Environment
tbls version
1.85.0
Database version
json DSN
OS ( Ubuntu bionic, macOS Calalina, WSL2, etc )
Windows 11
Shell ( bash, zsh, poworshell, etc )
poworshell
Stacktrace or error message from tbls ( If you can, set DEBUG=1)
Config ( .tbls.yml )
# .tbls.ymldsn: json://schema.jsondocPath: doc/schemaformat:
# Adjust the column width of Markdown format table# Default is falseadjust: false# Sort the order of table list and columns# Default is falsesort: true# Display sequential numbers in table rows# Default is falsenumber: false# The comments for each table in the Tables section of the index page will display the text up to the first double newline (first paragraph).# Default is falseshowOnlyFirstParagraph: false# Hide table columns without values# Default is falsehideColumnsWithoutValues: false# It can be boolean or array# hideColumnsWithoutValues: ["Parents", "Children"]er:
# Skip generation of ER diagram# Default is falseskip: false# ER diagram image format (`png`, `jpg`, `svg`, `mermaid`)# Default is `svg`format: mermaid# Add table/column comment to ER diagram# Default is falsecomment: false# Hide relation definition from ER diagram# Default is falsehideDef: false# Show column settings in ER diagram. If this section is not set, all columns will be displayed (default).showColumnTypes:
# Show related columnsrelated: true# Show primary key columnsprimary: true# Distance between tables that display relations in the ER# Default is 1distance: 2# ER diagram (png/jpg) font (font name, font file, font path or keyword)# Default is "" (system default)font:
include:
- Account
- Contact
What happened
When filtering tables in the input schema with
include
in.tbls.yml
, theer.showColumnTypes.related/primary
setting to hide columns other than PK and FK in the ER diagram output no longer works.When I wrote all tables in the input schema in the
include
(even with wildcards), the problem did not occur.What you expected to happened
I expect that even if
include
is set, columns other than PK and FK will be hidden in the same way as if it were not set.What stack trace or error message from tbls did you see?
Anything else we need to know?
Environment
tbls version
1.85.0
Ubuntu bionic
,macOS Calalina
,WSL2
, etc )Windows 11
bash
,zsh
,poworshell
, etc )poworshell
DEBUG=1
)schema.json
memo
Isn't
len(cc.ChildRelations) > 0 || len(cc.ParentRelations) > 0
correct?tbls/config/config.go
Lines 594 to 605 in adffc63
tbls/schema/filter.go
Lines 110 to 125 in adffc63
The text was updated successfully, but these errors were encountered: