src/db/DB.class.php
public function fetchColumn($query, array $values) {
		$col = null;
		try {
			$statement = $this->pdo->prepare($query);
			if ($statement->execute($values)) {
				$col = $statement->fetchColumn();
				if (!$col) return null;
			} else {
				$errorInfo = $statement->errorInfo();
				error_log($errorInfo[2]);
			}
		} catch (PDOException $e) {
			error_log($e->getMessage());
		}
		return $col;
	}
public function fetchColumn($query, array $values) {
		$col = null;
		try {
			$statement = $this->pdo->prepare($query);
			if ($statement->execute($values)) {
				$col = $statement->fetchColumn();
				if (!$col) return null;
			} else {
				$errorInfo = $statement->errorInfo();
				error_log($errorInfo[2]);
			}
		} catch (PDOException $e) {
			error_log($e->getMessage());
		}
		return $col;
	}
Retrieve first column in results set

@param string $query
@param array $values
@return string