Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLDR-15850 Add vote_type column if not present in current table #2792

Merged
merged 1 commit into from
Mar 17, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1753,6 +1753,14 @@ private synchronized void setupDB() {
s = null; // don't close twice.
conn.commit();
System.err.println("Created table " + DBUtils.Table.VOTE_VALUE);
} else if (!DBUtils.tableHasColumn(conn, DBUtils.Table.VOTE_VALUE.toString(), VOTE_TYPE)) {
s = conn.createStatement();
sql = "ALTER TABLE " + DBUtils.Table.VOTE_VALUE + " ADD COLUMN " + VOTE_TYPE + " TINYINT NOT NULL";
s.execute(sql);
s.close();
s = null;
conn.commit();
System.err.println("Added column " + VOTE_TYPE + " to table " + DBUtils.Table.VOTE_VALUE);
}
if (!DBUtils.hasTable(DBUtils.Table.VOTE_VALUE_ALT.toString())) {
s = conn.createStatement();
Expand Down