public static function create(array $tokens) {
        HashMap::assert($tokens, 'tokens');

        if (empty($tokens['WHERE'])) return '';

        $idAlias = self::alias($tokens);

        return array_reduce($tokens['WHERE'], function($carry, $token) use ($tokens, $idAlias) {
            if ($carry !== null) return (string)Value::create($carry);
            if ($token['expr_type'] === 'colref' && $token['base_expr'] === $idAlias) return $tokens['WHERE'][$carry+2]['base_expr'];
            if (!isset($tokens[$carry+1])) return '';
        }, null);
    }