synth icon indicating copy to clipboard operation
synth copied to clipboard

partial import support

Open zvif-orca opened this issue 3 years ago • 0 comments

Required Functionality Importing DB scheme is a complex task with many possible points of failure. I always believe that something is better than nothing - Allowing to ignore errors and import part of the scheme can become very handy. In some cases it would be even worth to fill the gaps manually until the DB will have better support.

Proposed Solution There are two main options as I see it, Synth may offer both:

  • skip-failed-tables - build partial scheme, skipping the problematic tables and other tables dependent on them.
  • ignore-errors - add the failed tables with missing data so the user can fill the missing. generate should validate that the user fixed the problems and exit accordingly.

Both options should be suggested to the user upon import failure, along with detailed report contains the problematic table/column name and cause - if the table was skipped because it dependent on problematic table - it should be specified in the cause

Use case

  • Scan fails, the user see that the failure is related to two small tables and chooses to use skip-failed-tables as suggested in the error
  • Scan fails, the user see that many tables are were skipped because they are depended in one problematic table. The user chooses to use the ignore-errors and fix the problematic table

zvif-orca avatar Sep 19 '22 21:09 zvif-orca