Project

General

Profile

Revision ba7d0c9a

IDba7d0c9a707dfb2d223c0c152a10cf157d010a96
Parent f50c5671
Child c220794b

Added by Andreas Müller almost 2 years ago

Add SchemaUpdater_55_551

View differences:

cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/database/update/v50_55/SchemaUpdater_55_551.java
1
/**
2
 * Copyright (C) 2007 EDIT
3
 * European Distributed Institute of Taxonomy
4
 * http://www.e-taxonomy.eu
5
 *
6
 * The contents of this file are subject to the Mozilla Public License Version 1.1
7
 * See LICENSE.TXT at the top of this package for the full license terms.
8
 */
9

  
10
package eu.etaxonomy.cdm.database.update.v50_55;
11

  
12
import java.util.ArrayList;
13
import java.util.List;
14

  
15
import org.apache.log4j.Logger;
16

  
17
import eu.etaxonomy.cdm.database.update.ISchemaUpdater;
18
import eu.etaxonomy.cdm.database.update.ISchemaUpdaterStep;
19
import eu.etaxonomy.cdm.database.update.SchemaUpdaterBase;
20

  
21
/**
22
/**
23
 * @author a.mueller
24
 * @date 09.06.2017
25
 *
26
 */
27
public class SchemaUpdater_55_551 extends SchemaUpdaterBase {
28

  
29
	@SuppressWarnings("unused")
30
	private static final Logger logger = Logger.getLogger(SchemaUpdater_55_551.class);
31
	private static final String startSchemaVersion = "5.5.0.0.20190221";
32
	private static final String endSchemaVersion = "5.5.1.0.20190301";
33

  
34
	// ********************** FACTORY METHOD *************************************
35

  
36
	public static SchemaUpdater_55_551 NewInstance() {
37
		return new SchemaUpdater_55_551();
38
	}
39

  
40
	/**
41
	 * @param startSchemaVersion
42
	 * @param endSchemaVersion
43
	 */
44
	protected SchemaUpdater_55_551() {
45
		super(startSchemaVersion, endSchemaVersion);
46
	}
47

  
48
	@Override
49
	protected List<ISchemaUpdaterStep> getUpdaterList() {
50

  
51
		String stepName;
52
		String tableName;
53
		ISchemaUpdaterStep step;
54
		String newColumnName;
55
		String query;
56

  
57
		List<ISchemaUpdaterStep> stepList = new ArrayList<>();
58

  
59

  
60
//		//#6699 delete term version
61
//		//just in case not fixed before yet
62
//		stepName = "Delete term version";
63
//		query = "DELETE FROM @@CdmMetaData@@ WHERE propertyName = 'TERM_VERSION'";
64
//		step = SimpleSchemaUpdaterStep.NewNonAuditedInstance(stepName, query, -99);
65
//        stepList.add(step);
66

  
67

  
68
        //TODO remove proparte and partial columns
69

  
70

  
71
        return stepList;
72

  
73
	}
74

  
75

  
76

  
77
    @Override
78
	public ISchemaUpdater getNextUpdater() {
79
		return null;
80
	}
81

  
82
	@Override
83
	public ISchemaUpdater getPreviousUpdater() {
84
		return SchemaUpdater_50_55.NewInstance();
85
	}
86

  
87
}

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)