def update_query(context, **kwargs):
    """Construct an URL contains only the querystring (excluding "?") by updating the current URL's querystring with the provided arguments."""
    request = context['request']
    query = request.GET.copy()
    for k, v in kwargs.items():
        query[k] = v
    return query.urlencode()