code: protected function importDataFile(string $dataFile, string $controlTableName = null): void
      {
          if ($controlTableName !== null) {
              $query = $this->db->createQueryBuilder();
              $query->select('count(*) AS count')
                  ->from($controlTableName);
  
              $data = $query->execute()->fetchAll();
  
              $contentCount = (int) $data[0]['count'];
              if ($contentCount > 0) {
                  $this->output->writeln('<comment>Data already exists in the database, skipping data import for file <info>' . $dataFile . '</info></comment>');
  
                  return;
              }
          }
  
          $this->runQueriesFromFile($dataFile);
      }
docs: Handle inserting of sql dump, sql dump should ideally be in ISO SQL format.
  
  Data file is created with: mysqldump ngsite --no-create-info --extended-insert=false > data.sql