Forum Discussion
OK did that, no real change. Still not ranking correctly.
------------------------------
Thanks,
Chris Newsome
------------------------------
- ChayceDuncan2 years agoQrew Captain
Have you submitted a ticket to QB support yet? I tried a handful of iterations in a smaller environment to your use case and there is something about the size(getrecords inside of the same table for some reason that it's not able to evaluate that I can't get to work. I found this by doing a query just to count values that were GT an arbitrary number and got 0. I did the same query in a different table and it returned an expected result. I tried playing with the single quote syntax and including / omitting it, aliasing the DBID, hard coding the DBID, leaving it out. This seems to be some kind of bug I haven't seen before.
Your query and the expected results all look right. I even went as far as trying to make a query field that counted the number of records with a higher record ID# and it wouldn't return anything which is impossible.
------------------------------
Chayce Duncan
------------------------------ - ChrisNewsome2 years agoQrew Captain
I haven't. I typically assume that I've missed some simple thing first before I go that route.
The thing is, it's not returning the correct results. I'm wanting to rank by the Won Value (YTD) field, and it ranks a customer that is at $277k at #1, and also a customer that is $91k at #1, which doesn't make any sense.
I am going to submit a feature request though to simply add the ability to limit results to X number... that's really all I need it do: "Only show 20 records." Quick Base is amazing but at times I'm dumbfounded that simple things like this aren't easily achievable.
------------------------------
Thanks,
Chris Newsome
------------------------------ - ChayceDuncan2 years agoQrew Captain
The Size(GetRecords is the current method that I would recommend similar to the others in this thread. Again - I tried just using the Record ID# to fake a ranking value and I couldn't get it to work either so something is off I believe.
Depending on what you need this report for - you can use the API and do your own query - https://developer.quickbase.com/operation/runQuery - there is a parameter for options where you can set the 'top' and return only the number of records you want. This only works if you were doing a code page or trying to export/create a CSV, but an option nonetheless.
------------------------------
Chayce Duncan
------------------------------ - ChrisNewsome2 years agoQrew Captain
I appreciate the info. The goal is to make a report for the Sales dept that they can run on demand to see who our top customers are. I'm actually comparing their volume from this year to last year. Everything on the report is fine, I just don't need 300 results... just the top 15-20. The ranking formula attempted in this thread was done as a report formula instead of a field itself based on the earlier replies about slowing the system down. So the goal is something that can be run with one click, easily, by a standard user of the app, so I don't think the other options you outlined would work.
I go back to my earlier comment - I can't believe it's not just a standard option to limit results to X number. Seems so basic.
------------------------------
Thanks,
Chris Newsome
------------------------------