Hey ! Do you want another tricky question ??? Again concerning sorting…
Ninox Profile

One thing that is great in ninox is the way we can group records…

Another thing that is great and super easy is to count the number of records in each group…

But… now… i would like my groups to be sorted by the number of records they have in them ???

Any genious with a good method ??? Am i missing something simple ?

Thanks all

Ninox Profile

You are! 😎 This requires another Formula field and this is the code I used...

 

let t := this;
count(select YourTable where Choice = t.Choice)

Ninox Profile

Well, well, well… this is not what i was waiting for… i wanted to re-sort the tabular mode… you know, the simple screen…

The problem with the count method is "the time it takes"… even with the "do as server" trick…

Right now i have 29249 records and about 150 choices… i'm a little afraid of lauching that count method… i'm going to have the spinning wheel for a while… and i even might lose it…

Ninox Profile

I guess I'm not sure what you mean by "tablular mode" unless you are referring to the table view. If you are referring to the table view, that solution works. You just click on the Formula field column header and choose your sort preference.

 

I admit I do most of my work locally with the Mac app so I don't experience the lags that cloud users experience. Having said that, I find that making even a small change on the cloud version is much slower than working locally.

Ninox Profile

@Laurent... How "dynamic" do the rankings have to be?  If 100% .. then per the other thread... You could create a "choice table" .. and add a function to that table for the sort..  If daily, weekly (etc) ..   You could create code behind a button that populates the record count.  

I have  a table with over 33,000 rows.. but only about 18 variation groups.. it is World Health Organization (WHO) standard deviation data... not your 180.... and a count button processed them in about 3 seconds. 

Ninox Profile

oh boy… i just had finished answering sean and i was kicked of !!! i hate that ! i lost all my content…

Ninox Profile

i'll come back a little later and answer both sean and mconneen ! sorry folks !

Ninox Profile

@sean

Yes tabular mode = table view, sorry...

i might not be very clear, let me take an example

let's say we have 2 fields

field A or column A is a ref.

field B or column B is a text

if I click on column A header, i can select "total"

if i click on column B header, i can select "group"

now if I close all the sections I can easily find out how many (looking in A) records have the B content... what I would like is to sort those A results...

for example, i would say my top B content is abc, followed by def, then it appears to be ghi, and so on...

grouping 30000 records by 150 items is one second !

ninox is soooooo fast for grouping and so slow for counting... i'm sure some codes aren't optimized there...

 

yes i'm on cloud version right now

i tried the count method and i stopped after 15 min - no results !

i also tried the "do as server..." : not better there...

i also have a mac app, but I still fetch my data on the cloud...

never tried much ninox locally with the mac app...

i guess speed then depends on the machine and the ssd inside it...

Ninox Profile

@mconneen

3 seconds !!! Do you have a Mac Pro ???

18 is not 150 but that sure is fast !

maybe the count is faster with integers ?

my "B" column is text...

maybe I'll have to test 100% locally, I might be very surprised, I have a HD but 20GO of RAM...

Ninox Profile

By the way, I don't know if ninox app uses that extra ram ???

1 2
Reply