Unlock records belonging to the current user.

@param  string  $tableName
@return bool
175005
public function unlockMyRecords($tableName)
    {
        $results = $this->lockedRecordsByUser($tableName, Auth::user()->id);

        foreach($results as $result)
        {
            $this->unpopulateLockFields($result->id);
        }
    }
96530
public function logout( $table_name ){
		$user_info = $this->exdb->session()->get('user_info');
		if(!is_array($user_info)){
			$user_info = array();
		}
		unset($user_info[$table_name]);
		$this->exdb->session()->set('user_info', $user_info);
		return true;
	}
1370213
public function tableExists( $tablename )
	{
		$sql = "
			SELECT TABLE_NAME
			FROM INFORMATION_SCHEMA.TABLES
			WHERE TABLE_TYPE = 'BASE TABLE'
				AND TABLE_SCHEMA = ?
				AND TABLE_NAME = ?
		";

		$stmt = $this->_conn->create( $sql );
		$stmt->bind( 1, $this->_dbname );
		$stmt->bind( 2, $tablename );
		$result = $stmt->execute();

		if( $result->fetch() !== false ) {
			return true;
		}

		return false;
	}
874319
private function getKeyNameForTable($tableName)
    {
        return isset($this->tableKeys[$tableName]) ?
          $this->tableKeys[$tableName] :
          $this->defaultKeyName;
    }
394569
public function fixTableCase($tableName)
    {
        // Check if table exists
        $tables = $this->tableList();
        if (!array_key_exists(strtolower($tableName), $tables)) {
            return;
        }

        // Check if case differs
        $currentName = $tables[strtolower($tableName)];
        if ($currentName === $tableName) {
            return;
        }

        $this->alterationMessage(
            "Table $tableName: renamed from $currentName",
            "repaired"
        );

        // Rename via temp table to avoid case-sensitivity issues
        $tempTable = "__TEMP__{$tableName}";
        $this->renameTable($currentName, $tempTable);
        $this->renameTable($tempTable, $tableName);
    }
710121
public function unlockTable()
    {
        $query = 'UNLOCK TABLES';

        // Create commandchain context.
        $context = $this->getCommandContext();
        $context->table = $base;
        $context->query = $query;

        if ($this->getCommandChain()->run('before.unlocktable', $context) !== false) {
            $context->result = $this->execute($context->query, AnDatabase::RESULT_USE);
            $this->getCommandChain()->run('after.unlocktable', $context);
        }

        return $context->result;
    }
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;
    }
653637
public function hasField($tableName, $fieldName)
    {
        if (!$this->hasTable($tableName)) {
            return false;
        }
        $fields = $this->fieldList($tableName);
        return array_key_exists($fieldName, $fields);
    }
520709
function unlock()
    {
        if ( $fp = $this->fp() )
        {
            fclose( $fp );
            @unlink( $this->MetaFileName );
            @unlink( $this->FileName );
            $GLOBALS['eZMutex_FP_' . $this->FileName] = false;
        }
        return false;
    }
251972
protected function tableExists($tableName) {
		if(isset($this->nonExistingTables[$tableName]))
			return false;
		if(isset($this->existingTables[$tableName]))
			return true;
		$exists = $this->schemaManager->tablesExist(array(
			$tableName 
		));
		if(!$exists) {
			$this->nonExistingTables[$tableName] = 1;
		} else {
			$this->existingTables[$tableName] = 1;
		}
		return $exists;
	}
311448
public function from($tableName, $alias = null)
    {
        $rel = $this->currentOrClone();
        
        if ($alias) {
            $rel->select->from([$alias => $tableName]);
        } else {
            $rel->select->from($tableName);
        }
        return $rel;
    }
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;
    }
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;
    }
945220
public function tableExists($tableName)
    {
        $sm = $this->getSchemaManager();
        $schemaTables = $sm->listTableNames();

        return in_array(strtolower($tableName), array_map('strtolower', $schemaTables));
    }
1106351
protected function tableExist($tableName)
    {
        /** @var \Doctrine\DBAL\Schema\AbstractSchemaManager $sm */
        $sm = $this->dbHandler->getConnection()->getSchemaManager();
        foreach ($sm->listTables() as $table) {
            if ($table->getName() == $tableName) {
                return true;
            }
        }

        return false;
    }
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']);
    }
234833
public function clearLock($name)
    {
        if (!isset($this->locks[$name])) {
            return false;
        }

        unset($this->locks[$name]);
        return true;
    }