|
|
|
@ -32,7 +32,6 @@ import java.sql.Date;
|
|
|
|
|
import java.sql.PreparedStatement;
|
|
|
|
|
import java.sql.ResultSet;
|
|
|
|
|
import java.sql.SQLException;
|
|
|
|
|
import java.sql.Statement;
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
|
import java.util.HashMap;
|
|
|
|
|
import java.util.List;
|
|
|
|
@ -56,7 +55,7 @@ public class GenericApplicationReleaseDAOImpl extends AbstractDAOImpl implements
|
|
|
|
|
String sql = "insert into APPM_APPLICATION_RELEASE(VERSION_NAME, RELEASE_RESOURCE, RELEASE_CHANNEL ,"
|
|
|
|
|
+ "RELEASE_DETAILS, CREATED_AT, APPM_APPLICATION_ID, IS_DEFAULT) values (?, ?, ?, ?, ?, ?, ?)";
|
|
|
|
|
int index = 0;
|
|
|
|
|
String generatedColumns[] = { "ID" };
|
|
|
|
|
String generatedColumns[] = {"ID"};
|
|
|
|
|
try {
|
|
|
|
|
connection = this.getDBConnection();
|
|
|
|
|
statement = connection.prepareStatement(sql, generatedColumns);
|
|
|
|
@ -199,9 +198,9 @@ public class GenericApplicationReleaseDAOImpl extends AbstractDAOImpl implements
|
|
|
|
|
throws ApplicationManagementDAOException {
|
|
|
|
|
Connection connection;
|
|
|
|
|
PreparedStatement statement = null;
|
|
|
|
|
String sql = "UPDATE APPM_APPLICATION_RELEASE SET RELEASE_RESOURCE = IFNULL (?, RELEASE_RESOURCE), RELEASE_CHANNEL = IFNULL "
|
|
|
|
|
+ "(?, RELEASE_CHANNEL), RELEASE_DETAILS = IFNULL (?, RELEASE_DETAILS), IS_DEFAULT = IFNULL "
|
|
|
|
|
+ "(?, IS_DEFAULT) WHERE APPM_APPLICATION_ID = ? AND VERSION_NAME = ?";
|
|
|
|
|
String sql = "UPDATE APPM_APPLICATION_RELEASE SET RELEASE_RESOURCE = IFNULL (?, RELEASE_RESOURCE)," +
|
|
|
|
|
" RELEASE_CHANNEL = IFNULL (?, RELEASE_CHANNEL), RELEASE_DETAILS = IFNULL (?, RELEASE_DETAILS), " +
|
|
|
|
|
"IS_DEFAULT = IFNULL (?, IS_DEFAULT) WHERE APPM_APPLICATION_ID = ? AND VERSION_NAME = ?";
|
|
|
|
|
try {
|
|
|
|
|
connection = this.getDBConnection();
|
|
|
|
|
statement = connection.prepareStatement(sql);
|
|
|
|
@ -311,6 +310,7 @@ public class GenericApplicationReleaseDAOImpl extends AbstractDAOImpl implements
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* To insert the application release properties.
|
|
|
|
|
*
|
|
|
|
|
* @param connection Database Connection
|
|
|
|
|
* @param applicationRelease Application Release the properties of which that need to be inserted.
|
|
|
|
|
* @throws SQLException SQL Exception.
|
|
|
|
|