Forum Discussion

Suchith's avatar
7 years ago

How to fetch Users Data based on Sort or Order by id Using V2 API.

Hi,  I have couple of question regarding Fetching User Data using V2 API. In my use case. I want to fetch all the registered user from community. For this, I am getting total count of user and ...
  • VikasB's avatar
    7 years ago

    Suchith

     Most of the user's field does not exist for object 'users' as a sort constraint, not even id. But you can sort it by registration time. It would work in an expected way. 

    select * from users order by registration_data.registration_time desc

    When you increment the offset each time, it would not fetch the same result again.