realm-js icon indicating copy to clipboard operation
realm-js copied to clipboard

Distinct / group by support?

Open sharq1 opened this issue 8 years ago • 17 comments

It would be very useful to have.

sharq1 avatar Jun 07 '16 08:06 sharq1

I vote

ravitez avatar Aug 27 '16 15:08 ravitez

+1

289420843 avatar Sep 28 '16 12:09 289420843

@alazier, is there any workaround available for distinct and group by support in realm js

ugendrang avatar May 28 '17 15:05 ugendrang

also support this idea and am curious if there are workarounds available

kevboh avatar Aug 25 '17 19:08 kevboh

At the moment the only way to achieve this is to pull all your data and use something like lodash to accomplish it I'm afraid.

kristiandupont avatar Aug 28 '17 08:08 kristiandupont

Fair enough, thanks for the quick answer. In general, is there any way to see and upvote the realm-js roadmap beyond github issues?

kevboh avatar Aug 28 '17 18:08 kevboh

Not at the moment, no. However, we do monitor GitHub as it's what we use for our internal project planning so we do take notice when people comment in here.

kristiandupont avatar Aug 29 '17 08:08 kristiandupont

I see—thanks for clarifying!

kevboh avatar Aug 29 '17 11:08 kevboh

+1

sajjadrad avatar Sep 09 '17 17:09 sajjadrad

+1

vivekkhurana avatar Sep 11 '17 02:09 vivekkhurana

+1

Almjz avatar Sep 28 '17 08:09 Almjz

+1

kosiakMD avatar Oct 25 '17 09:10 kosiakMD

+1

faogustavo avatar Nov 14 '17 15:11 faogustavo

+1

badaz avatar Dec 05 '17 21:12 badaz

+1

andrew-wagner89 avatar Feb 21 '18 20:02 andrew-wagner89

Is this supposed to be supported 2.3.x? Per the current documentation page:

Sorting and find distinct values are possible with functions SORT and DISTINCT, e.g. age > 20 SORT(name ASC, age DESC) DISTINCT(name).

I have tried to use these functions without success. I also have an open question on StackOverflow that is still unanswered.

sellmeadog avatar Apr 21 '18 22:04 sellmeadog

Yes, this seems to work well with a predicate followed by sort and distinct. I even made it work with a relation: time != null SORT(activity.id ASC, time DESC) DISTINCT(activity)

reyalpsirc avatar Feb 11 '19 11:02 reyalpsirc