mermerd icon indicating copy to clipboard operation
mermerd copied to clipboard

Duplication of columns on each table

Open matthewmichel opened this issue 3 years ago • 1 comments

Love this tool! Using it for a MySQL instance hosted on AWS RDS. I'm running into an issue causing 95% (not all) of the columns in each table to duplicate twice (for a total of three columns with the same name/type). The process runs and completes successfully with the duplication issue and it also doesn't generate any constraints even though they're set up from the MySQL side.

Has this been fully tested on a MySQL db? Just want to make sure I'm doing everything right. Here's an example of the yaml file I'm using to run the process:

# Connection properties
connectionString: "mysql://username:password@tcp(database.identifier.us-region-1.rds.amazonaws.com:3306)/default-schema"

# Define what tables should be used
useAllTables: true

# Additional flags
showAllConstraints: true
encloseWithMermaidBackticks: true
outputFileName: "default-schema-mermerd.md"
debug: true
omitConstraintLabels: true

There is a hyphen "-" in our schema name. Could that be causing a problem? The only odd thing I've noticed is that (because it's MySQL) we're specifying the schema in the connection string and then the CLI asks again for the schema once it connects to the db instance. That might just be a MySQL thing because I know Postgres is set up differently to have a DB and then have Schemas under each DB whereas MySQL considers schemas like Postgres does a database.

Thanks!

matthewmichel avatar Sep 08 '22 17:09 matthewmichel

Glad you find the tool useful :)

All supported databases are automatically tested via the integration tests (but with a defined set of tables, so not all edge cases are covered)

Could you provide the ddl statements for the tables that caused the issue? Then I can easily reproduce/analyze the issue and add a testcase to prevent the issue for future changes.

KarnerTh avatar Sep 08 '22 18:09 KarnerTh

Closing this issue due to inactivity. If the issue is still present feel free to reopen it.

KarnerTh avatar Feb 07 '23 19:02 KarnerTh