If I compare (ddl compare via schema browser right click) two databases in MySQL 5.1, the compare results show word/character highlighting of differences. Same is true for Oracle 11g, Sybase ASE 15.0.
If I compare (ddl compare via schema browser right click) two databases in MS SQL Server 2000, the compare results do not show word/character highlighting differences.
the attached screenshots illustrate the issue taken with v9.0.0-beta1.01
I just tested this on beta1.03, still the same
Version: 9.0.0-beta1.03
Build #: 15365
Build Date: 2010-Jul-11 10:27:29 AM
Operating Environment: Windows XP (5.2, amd64) / Cp1252 / en / US / Sun Microsystems Inc. 1.6.0_20-b02
Memory: Max=3,728,277,504; Total=737,607,680; Free=484,901,544; CPUs=8
Graphics Vendor: NVIDIA Corporation
OpenGL Renderer: Quadro FX 1700/PCI/SSE2
OpenGL Version: 3.0.0
Double-Buffering: Disabled
Anti-Aliasing: Enabled
Anti-Aliasing Sample Count: 16
Hardware Acceleration: Enabled
Hardware PBuffer Available: Yes
Using PBuffer: Yes
Using Ram Buffer: No
Offscreen Rendering: Enabled
Offscreen Buffer Size: 1600x1200
Color Bits: Red: 8 Green: 8 Blue: 8 Alpha: 8
Depth Bits: 24
Accumulation Buffer Bits: Red: 16 Green: 16 Blue: 16
|
57 KB
|
64 KB
|
74 KB
|
69 KB
![]() |
210 KB
![]() |
2 KB
|
46 KB
|
53 KB
|
54 KB
|
52 KB
|
52 KB
|
14 KB
That is interesting, because if I use the Tab Compare with a manual DDL script, then it compares by words. I've attached file NIELS_BASE.png ... and you can use these steps to reproduce ...
1. navigate to SQL Server 2000 database fcy_db_test and Script CREATE to Window
2. navigate to SQL Server 2000 database fcy_db_diff_1 and Script CREATE to NEW Window
3. right mouse click on tab and compare the two. See attached script.
so, we have two issues here:
1. The netbeans diff algorithm would lump certain changes into one and refuse to highlight word differences (see screenshots A1 and A2). Both are results of comparing the same DDL, except in A1 a line was inserted, effectively breaking the big block into smaller blocks.
2. Tab Compare function (invoked on right click on an editor tab and selecting Compare) and DDL Compare (highlight two nodes in a schema tree and select Compare) would produce different results, as illustrated on screenshots A3 and A4. Both are result of comparing the same DDL, but the highlight is shifted in schema compare (A3).
screenshot 'options' lists my schema compare options.
so, we have two issues here:
1. The netbeans diff algorithm would lump certain changes into one and refuse to highlight word differences (see screenshots A1 and A2). Both are results of comparing the same DDL, except in A1 a line was inserted, effectively breaking the big block into smaller blocks.
2. Tab Compare function (invoked on right click on an editor tab and selecting Compare) and DDL Compare (highlight two nodes in a schema tree and select Compare) would produce different results, as illustrated on screenshots A3 and A4. Both are result of comparing the same DDL, but the highlight is shifted in schema compare (A3).
screenshot 'options' lists my schema compare options.
Analysis.
We are using a hacked netbeans diff and a hacked netbeans diff presenter components. The netbeans people write their code in such a way that makes it nearly impossible to extend or reuse: by using private, final, but worst of all, relying on their Lookup service and their backwards design where objects are created deep inside and way later.
Problem number 2 is caused by the fact that the diff is computed by the schema diff code which uses schema compare settings, but it gets rendered by the presenter component which uses a different diff object and corresponding settings. (We had a similar problem in multiple schema compare where the number of differences in the table is not the same as in the diff view).
I would suggest that we 'fork' the diff code by ripping it completely out of the netbeans hierarchy, getting rid of their lookup and re-engineering it to make it more extendable, or at least configurable. This is a large chunk of work though. We may want to do this with the latest netbeans code possibly (if it works!).
Alternatively, we should find a better diff/presenter combination.
The ultimate decision should also take into account the three-way merge.
PS. Niels wants me to re-assign this issue to him.
Analysis.
We are using a hacked netbeans diff and a hacked netbeans diff presenter components. The netbeans people write their code in such a way that makes it nearly impossible to extend or reuse: by using private, final, but worst of all, relying on their Lookup service and their backwards design where objects are created deep inside and way later.
Problem number 2 is caused by the fact that the diff is computed by the schema diff code which uses schema compare settings, but it gets rendered by the presenter component which uses a different diff object and corresponding settings. (We had a similar problem in multiple schema compare where the number of differences in the table is not the same as in the diff view).
I would suggest that we 'fork' the diff code by ripping it completely out of the netbeans hierarchy, getting rid of their lookup and re-engineering it to make it more extendable, or at least configurable. This is a large chunk of work though. We may want to do this with the latest netbeans code possibly (if it works!).
Alternatively, we should find a better diff/presenter combination.
The ultimate decision should also take into account the three-way merge.
PS. Niels wants me to re-assign this issue to him.
Issue #4732 |
Unconfirmed |
Completion |
No due date |
No fixed build |
No time estimate |
That is interesting, because if I use the Tab Compare with a manual DDL script, then it compares by words. I've attached file NIELS_BASE.png ... and you can use these steps to reproduce ...
1. navigate to SQL Server 2000 database fcy_db_test and Script CREATE to Window
2. navigate to SQL Server 2000 database fcy_db_diff_1 and Script CREATE to NEW Window
3. right mouse click on tab and compare the two. See attached script.