prefs.setQuoteColumnNames(false);
// MySQL disallows quoted constraint names
prefs.setQuoteConstraintNames(false);
return super.getColumnDropSQL(tableName, columnName, qualifier, prefs);
prefs.setQuoteColumnNames(false);
// MySQL disallows quoted constraint names
prefs.setQuoteConstraintNames(false);
return super.getAddPrimaryKeySQL(pkName, colInfos, ti, qualifier, prefs);
Clone fragments detected by clone detection tool
File path: /sql12/fw/src/net/sourceforge/squirrel_sql/fw/dialects/MySQLDialectExt.java
|
|
File path: /sql12/fw/src/net/sourceforge/squirrel_sql/fw/dialects/MySQLDialectExt.java
|
Method name: String getColumnDropSQL(String, String, DatabaseObjectQualifier, SqlGenerationPreferences)
|
|
Method name: String[] getAddPrimaryKeySQL(String, TableColumnInfo[], ITableInfo, DatabaseObjectQualifier, SqlGenerationPreferences)
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | prefs.setQuoteColumnNames(false);↵ | | 1 | prefs.setQuoteColumnNames(false);↵
|
2 | // MySQL disallows quoted constraint names↵ | | 2 | // MySQL disallows quoted constraint names↵
|
3 | prefs.setQuoteConstraintNames(false);↵ | | 3 | prefs.setQuoteConstraintNames(false);↵
|
4 | ↵ | | 4 | ↵
|
5 | return super.getColumnDropSQL(tableName, columnName, qualifier, prefs); | | 5 | return super.getAddPrimaryKeySQL(pkName, colInfos, ti, qualifier, prefs);
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 9 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
1 | prefs.setQuoteColumnNames(false); | | 1 | prefs.setQuoteColumnNames(false); |
2 | prefs.setQuoteConstraintNames(false); | | 2 | prefs.setQuoteConstraintNames(false); |
| | | 3 | return super.getAddPrimaryKeySQL(pkName, colInfos, ti, qualifier, prefs); |
3 | return super.getColumnDropSQL(tableName, columnName, qualifier, prefs); | | | |
Precondition Violations (0)
Row |
Violation |