Finish Hotfix-1
All checks were successful
IntegryManagementSystem_Multi/pipeline/head This commit looks good

This commit is contained in:
2024-12-12 17:22:23 +01:00
2 changed files with 9 additions and 2 deletions

View File

@@ -483,7 +483,7 @@ public class UtilityDB {
List<HashMap<String, Object>> queryResults = executeSimpleQuery(conn, querySql);
if (queryResults.size() > 0) {
if (!queryResults.isEmpty()) {
object = queryResults.get(0);
}

View File

@@ -23,6 +23,7 @@ import org.apache.logging.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.sql.Timestamp;
import java.time.LocalDate;
import java.util.ArrayList;
import java.util.HashMap;
@@ -120,9 +121,15 @@ public class ExchangeColliImportService {
AtomicInteger dataCount = new AtomicInteger(0);
AtomicInteger importedCounter = new AtomicInteger(0);
LocalDate startDate = LocalDate.of(2024, 7, 1);
String sqlMinDate = "SELECT MIN(data_collo) FROM " + testataTableName + (useTempTable ? "_tmp" : "");
Timestamp startDateTimeStamp = UtilityDB.executeSimpleQueryOnlyFirstRowFirstColumn(exchangeMultiDb.getPrimaryConnection(), sqlMinDate);
LocalDate startDate = startDateTimeStamp.toLocalDateTime().toLocalDate();
// LocalDate startDate = LocalDate.of(2024, 7, 1);
Result<Object> firstErrorObjectIfPresent = null;
while (startDate.minusDays(1).isBefore(UtilityLocalDate.getNow())) {
final LocalDate tempStartDate = startDate;