private Map<String, String> extractRowDataAsMap(ResultSet resultSet, ValueProcessor valueProcessor,
                                                    Map<String, String> primaryKeyMap) throws SQLException {
        ResultSetMetaData metaData = resultSet.getMetaData();
        Map<String, String> row = new HashMap<>(metaData.getColumnCount());
        for (int i = 1; i <= metaData.getColumnCount(); i++) {
            JDBCDataValue jdbcDataValue = new JDBCDataValue(resultSet, metaData, i, false);
            String columnName = metaData.getColumnName(i);
            String jdbcValueString = valueProcessor.getJdbcSqlValueString(jdbcDataValue);
            if (primaryKeyMap.containsKey(columnName)) {
                primaryKeyMap.put(columnName, jdbcValueString);
            } else {
                row.put(columnName, jdbcValueString);
            }
        }
        return row;
    }
@param connection
@param databaseExportDataParam
@param file
chat2db-server/chat2db-server-web/chat2db-server-web-api/src/main/java/ai/chat2db/server/web/api/controller/rdb/data/sql/SqlDataExporter.java