Skip to content

Support value variables for paging params (offset, after, first) #2564

@disconsented

Description

@disconsented
{

 var(func: eq(account, "100")){
   client{
       cid as uid  
   }
   msg as message_limit
 }
 messageCount(func: uid(cid)){
        count(messages)
   messages(orderdesc: timestamp, offset: val(msg)){
        uid
        payload
        timestamp
   }
 }
}

message_limit here is message_limit:int . .
The essential point is that I want to be able to set values in the database to use as limits application side. The above results in : strconv.ParseInt: parsing "msg": invalid syntax which seems inconsistent considering that variables can be used for ordering as suggested by the documentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Stalearea/querylangIssues related to the query language specification and implementation.area/querylang/paginationRelated to pagination: first, offset, etcarea/querylang/varsIssues related to queries with GraphQL variableskind/enhancementSomething could be better.popularpriority/P1Serious issue that requires eventual attention (can wait a bit)status/acceptedWe accept to investigate/work on it.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions