Checks if a migration tracker exists for a given datatable

@param string $tableName

@return bool
965052
public function has($tableName)
    {
        $capsules = $this->all();

        foreach ($capsules as $capsule) {
            if ($capsule->tableName == $tableName) {
                return true;
            }
        }

        return false;
    }
738582
public function isSearchable(string $tableName): bool
    {
        deprecationWarning(
            __METHOD__ . '() is deprecated. This should be handled by the application/business logic.'
        );

        list(, $tableName) = pluginSplit($tableName);

        $config = (new ModuleConfig(ConfigType::MODULE(), $tableName))->parse();
        if (! property_exists($config, 'table')) {
            return false;
        }

        if (! property_exists($config->table, 'searchable')) {
            return false;
        }

        return (bool)$config->table->searchable;
    }
1105098
public function clearTable(string $tableName): bool
    {
        $delete = new DeleteQuery($this->db);

        return $delete->from($tableName)->execute();
    }
1345467
public function getTableMetadata(string $tableName): TableMetadata
    {
        if (!array_key_exists($tableName, $this->tableMetadataList)) {
            throw new \RuntimeException('Database "' . $this->databaseName . '" doesn\'t contain table "' . $tableName . '"');
        }

        return $this->tableMetadataList[$tableName];
    }
62209
public static function get($tableName, $modelName, $resourceFile, array $migrationProperties = [])
    {
        $properties['table-name'] = $tableName;
        $properties['model-name'] = $modelName;
        $properties['resource-file'] = $resourceFile;
        $properties['migrations'] = $migrationProperties;

        return new MigrationTrackerCapsule($properties);
    }
405834
public function destroyFieldMigrationForTable($name, $tableName)
    {
        $path = $this->getMigrationPath($tableName, $name);

        $this->delete($path);
    }
1250670
public function existTable(string $tableName): bool
    {
        [$dbName, $tableName] = $this->parseTableName($tableName);

        $sql = 'SELECT table_name
            FROM information_schema.tables
            WHERE table_schema = %s
            AND table_name = %s;';

        $sql = sprintf($sql, $dbName, $tableName);
        $row = $this->db->query($sql)->fetch(PDO::FETCH_ASSOC);

        return isset($row['table_name']);
    }
419954
public function tableExists($tableName)
    {
        if (is_null($this->dbh)) {
            throw new NoConnectionException();
        }

        $mrSql  = "SHOW TABLES LIKE :table_name";
        $mrStmt = $this->dbh->prepare($mrSql);

        // protect from injection attacks
        $mrStmt->bindParam(":table_name", $tableName, \PDO::PARAM_STR);

        $sqlResult = $mrStmt->execute();

        if ($sqlResult) {
            $row = $mrStmt->fetch(\PDO::FETCH_NUM);

            if ($row[0]) {
                return true;
            }
        }

        return false;
    }
1132905
public boolean has(String tableName) {

		boolean exists = has(EXTENSION_NAME, tableName,
				TileTable.COLUMN_TILE_DATA);

		return exists;
	}
1304286
private function fieldExists($tableName, $columnName): bool
    {
        if (!\array_key_exists($tableName, $this->schemaCache)) {
            $this->schemaCache[$tableName] = $this->connection->getSchemaManager()->listTableColumns($tableName);
        }

        return isset($this->schemaCache[$tableName][$columnName]);
    }
579966
public function getTableCreateSql($tableName)
    {
        $sql = sprintf('SHOW CREATE TABLE %s', $this->ident($tableName));
        $result = $this->pdo->query($sql)->fetch();

        return $result['CREATE TABLE'];
    }
1057272
private function findAutoincrementSequence($tableName)
    {
        if (!$this->connection->getDatabasePlatform()->supportsSequences()) {
            return null;
        }

        $table = $this->findTableByName($tableName);
        $pkColumns = $table->getPrimaryKey()->getColumns();

        if (\count($pkColumns) !== 1) {
            return;
        }

        $tableSequenceName = \sprintf('%s_%s_seq', $table->getName(), $pkColumns[0]);
        $sequences = $this->getSchemaManager()->listSequences();
        foreach ($sequences as $sequence) {
            if ($tableSequenceName === $sequence->getName()) {
                return $sequence;
            }
        }
    }
1231329
protected function skipTable($tableName)
    {
        // Check if select options is set and table name is not selected
        if (count($this->option('select')) > 0 && !in_array($tableName, $this->option('select'), true)) {
            return true;
        }

        // Check if table name is ignored
        if (in_array($tableName, $this->option('ignore'), true)) {
            return true;
        }

        return false;
    }
92397
public function forgetMigration($tableName, $name)
    {
        $capsules = $this->all();
        $keep = [];

        foreach ($capsules as $capsule) {
            if ($capsule->tableName == $tableName) {
                $key = $capsule->getMigrationIndex($name);
                $capsule->forgetMigration($key);
            }

            $keep[] = $capsule;
        }

        $this->write($keep);

        return $keep;
    }
783725
public function existDatabase(string $dbName): bool
    {
        $sql = 'SELECT SCHEMA_NAME
            FROM INFORMATION_SCHEMA.SCHEMATA
            WHERE SCHEMA_NAME = %s;';

        $sql = sprintf($sql, $this->quoter->quoteValue($dbName));
        $row = $this->db->query($sql)->fetch(PDO::FETCH_ASSOC);

        return !empty($row['SCHEMA_NAME']);
    }
270493
public function TableExists($TableName = NULL) {
      if($this->_TableExists === NULL || $TableName !== NULL) {
         if ($TableName === NULL)
            $TableName = $this->TableName();

         if(strlen($TableName) > 0) {
            $Tables = $this->Database->SQL()->FetchTables(':_'.$TableName);
            $Result = count($Tables) > 0;
         } else {
            $Result = FALSE;
         }
         if ($TableName == $this->TableName())
            $this->_TableExists = $Result;
         return $Result;
      }
      return $this->_TableExists;
   }
1041594
public function tableExists($tableName, $connectionName = 'default')
    {
        try {
            $db = ConnectionManager::get($connectionName);
            $collection = $db->schemaCollection();
            $tables = $collection->listTables();
            if (in_array($tableName, $tables)) {
                return true;
            }
        } catch (PDOException $connectionError) {
            return false;
        }
        return false;
    }