Compares two table names.
The table names can be either quoted or unquoted. This method
will consider both cases.
@param string $name1 table name 1
@param string $name2 table name 2
@return boolean whether the two table names refer to the same table.
427089
public function compareTableNames($name1,$name2)
	{
		$name1=str_replace(array('[',']'),'',$name1);
		$name2=str_replace(array('[',']'),'',$name2);
		return parent::compareTableNames(strtolower($name1),strtolower($name2));
	}
877751
public function tablesExist($tableNames)
    {
        $tableNames = array_map('strtolower', (array) $tableNames);

        return count($tableNames) === count(array_intersect($tableNames, array_map('strtolower', $this->listTableNames())));
    }
667441
public static boolean compareQNames(QName qn1, QName qn2) {
        if (qn1 == qn2)
            return true;
        if (qn1 == null || qn2 == null)
            return false;
        return qn1.equals(qn2);
    }
511942
public function getTable($name)
    {
        return $this->tables->has($name) ? $this->tables[$name] : null;
    }
1100593
public static function table($name)
    {
        Validate::table($name)->exists();

        $self                  = new self();
        $self->tables['local'] = $name;

        return $self;
    }
228575
public function __isset($name)
    {
        switch ($name) {
            case 'rawValue':
                return ($this->rawValue !== null);
                break;
            case 'value':
                return ($this->value !== null);
                break;
            //return true;
        }
        return false;
    }
1226521
public function __isset( $name ) {
		$func = "get_{$name}";
		if ( method_exists( $this, $func ) ) {
			return true;
		}
		$func = "is_{$name}";
		if ( method_exists( $this, $func ) ) {
			return true;
		}

		return isset( $GLOBALS[ $name ] );
	}
129991
public static function table($name)
    {
        Helpers\Validate::table($name)->exists();

        $self       = new self();
        $self->name = $name;

        $self->setFields();
        $self->setPending();

        return $self;
    }
684764
protected function isNameUnique($name)
    {
        foreach (self::$SHEETS_NAME_USED[$this->associatedWorkbookId] as $sheetIndex => $sheetName) {
            if ($sheetIndex !== $this->index && $sheetName === $name) {
                return false;
            }
        }

        return true;
    }
410528
protected function resolveTableNames($table,$name)
	{
		$parts=explode('.',str_replace(array('[',']'),'',$name));
		if(($c=count($parts))==3)
		{
			// Catalog name, schema name and table name provided
			$table->catalogName=$parts[0];
			$table->schemaName=$parts[1];
			$table->name=$parts[2];
			$table->rawName=$this->quoteTableName($table->catalogName).'.'.$this->quoteTableName($table->schemaName).'.'.$this->quoteTableName($table->name);
		}
		elseif ($c==2)
		{
			// Only schema name and table name provided
			$table->name=$parts[1];
			$table->schemaName=$parts[0];
			$table->rawName=$this->quoteTableName($table->schemaName).'.'.$this->quoteTableName($table->name);
		}
		else
		{
			// Only the name given, we need to get at least the schema name
			//if (empty($this->_schemaNames)) $this->findTableNames();
			$table->name=$parts[0];
			$table->schemaName=self::DEFAULT_SCHEMA;
			$table->rawName=$this->quoteTableName($table->schemaName).'.'.$this->quoteTableName($table->name);
		}
	}
120702
public function __isset( $name ) {

		$name = (string) $name;

		if ( in_array( $name, array( '_data', 'data', 'total', 'total_rows', 'zebra' ), true ) ) {
			return true;
		} elseif ( in_array( $name, array( 'meta', 'meta_properties', 'meta_extra' ), true ) ) {
			return true;
		} else {
			return isset( $this->new->{$name} );
		}
	}
506714
public function hasDatabase($name)
    {
        foreach ($this->databases as $database) {
            if ($database->getName() === $name) {
                return true;
            }
        }

        return false;
    }
481747
function isExist($name = null)
    {
        if (isset($name)){
            return isset($this->children[$name]);
        }
        return !$this->is_temp;
    }
892513
public static function tableExists($tableName)
    {
        $query = "SELECT 1 FROM $tableName LIMIT 1";

        try {
            $result = Connection::db()->query($query);
        } catch (Exception $e) {
            return false;
        }

        return $result !== false;
    }
174679
public function getDistance(string $name1, string $name2): float
    {
        return $this->handle->rawCommand('geodist', [$this->name, $name1, $name2]);
    }
62970
public boolean tableExists (Connection conn, String name) throws SQLException
    {
        ResultSet rs = conn.getMetaData().getTables(null, null, name, null);
        while (rs.next()) {
            String tname = rs.getString("TABLE_NAME");
            if (name.equals(tname)) {
                return true;
            }
        }
        return false;
    }
1118633
public function has($name): bool
    {
        $name = $this->getCacheKey($name);

        $sql    = 'SELECT value FROM ' . $this->options['table'] . ' WHERE var=\'' . $name . '\' AND (expire=0 OR expire >' . time() . ') LIMIT 1';
        $result = sqlite_query($this->handler, $sql);

        return sqlite_num_rows($result);
    }