Bug #34230 copy/paste from model-page to diagram creates inconsistent table
Submitted: 1 Feb 2008 14:27 Modified: 15 Feb 2008 23:12
Reporter: Johannes Taxacher Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Severity:S2 (Serious)
Version:5.0.12 beta OS:Windows
Assigned to: Johannes Taxacher CPU Architecture:Any

[1 Feb 2008 14:27] Johannes Taxacher
Description:
when copying a table to clipboard (Ctrl+C, or via menu) from MySQL Model Page and pasting (again via Ctrl+V or menuItem) it on a EER-Diagram canvas the created table is a duplicate of tha copied on and is drawn on the canvas, but it has the same name (rather than "table1_copy") and it has no representation on either the catalog view or the MySQL-Model page. The only place where it shows up other than the canvas is the layer view.
It actually is a new table because its editable and when changing details like the name doesn't affect the original copy/paste-source. 

How to repeat:
1) new document
2) create a table directly on MySQL Model Page (use default name and PK col)
3) right-click the table and select "Copy table1"
4) double click "Add Diagram"
5) on canvas paste the copied table1 via Ctrl+V or edit menu
6) "table1" is created on canvas
7) doubleclick the table and rename it (i.e. table1_duplicate)

Now the name on the canvas-figure changes but not the representations in catalog view or back on the Model-page - so it's not the same table but a duplicate thats nowhere else shown but on canvas and the layer-pane.

You can add the original table1 from catalog-view to the diagram by dragging it from catalog view as usual.

if you save and reload the file the tables are present in the file just as created/duplicated, but the "phantom-copy" on the canvas isn't drawn correctly as it was before (only visible in the navigator pane). but it's existent (at least somwhow) because the property window shows its properties.
[1 Feb 2008 14:28] Johannes Taxacher
demo-document I saved after step 7 above

Attachment: phantom_table.mwb (application/octet-stream, text), 3.68 KiB.

[15 Feb 2008 15:35] Johannes Taxacher
works now correct ... but I'd expect that the program really _copies_ the table - so that a table1_copy1 is put on the canvas (and added to the model of course) ... but I'm not sure if thats what the normal user would expect.
[15 Feb 2008 23:12] Peter Lavin
Thank you for your bug report. This issue has been addressed in the documentation. The updated documentation will appear on our website shortly, and will be included in the next release of the relevant products.
Added to the changelog.