Get rid of duplicated tables
Posted by Carmina Garcia on 05 June 2019 02:50 PM
When VE analyzes your code, it may find some references with a prefix indicating the schema containing your objects (schema.table for instance). Other references may not include such a prefix.
For example, the code could include these 2 phrases
In the second phrase the schema is not specified with a prefix.
In this case, VE assigns a default schema to the table called <default_schema>
As a consequence, the table list will includes these 2 tables:
Maybe this result is not accurate, because there is only 1”customer” table in the database. In this case, you fix this issue by defining the value of the default schema.
In the example above, if the default schema is set to “schema1”, then visual expert will create only the table schema1.customer after the code analysis.
First, you find the name of the database and schema containing the duplicated objects.
Then, you use these value as default database and schema in your VE project.
a. Open a list of objects in Visual Expert and select some duplicated objects.
c. note down the server, database and schema names.
d. go to Settings > Select Source code > Default DB Items > enter the names noted above.
e. click OK, and close the window.
f. refresh your source code analysis.
Once the analysis process is completed, check that the objects are no longer duplicated.