public static void loadSQLTextForStatements(List<SQLStatement> sqlStatements, ProgressListener progressListener) {
        if (progressListener != null) {
            progressListener.setStartValue(0);
            progressListener.setEndValue(sqlStatements.size());
            progressListener.setCurrentValue(0);
        }

        List<SQLStatement> sqlStatementsToLoad = new ArrayList<>();
        int numberStatements = 0;
        int progressCounter = 0;
        for (SQLStatement statement : sqlStatements) {

            sqlStatementsToLoad.add(statement);
            numberStatements++;
            if (numberStatements == NUMBER_BIND_VARIABLES_SELECT_SQL_TEXT) {

                loadSQLStatements(sqlStatementsToLoad);

                sqlStatementsToLoad.clear();
                numberStatements = 0;

                if (progressListener != null) {
                    progressListener.setCurrentValue(progressCounter);
                }
            }

            progressCounter++;
        }

        if (sqlStatementsToLoad.size() > 0) {
            // there are some statements left to load
            loadSQLStatements(sqlStatementsToLoad);
        }

        if (progressListener != null) {
            progressListener.informFinished();
        }
    }