Hi,
I currently have a report that returns a specific number of records using the rank function. The problem with that is that it always returns the same records everytime it is ran. Is it possible to return a random selection? Currently my code for returning records looks like this....
rank([CUSTOMERNUMBER])<6
Thank you for any help you can provide!
you can create a filter
rank([CUSTOMERNUMBER])<?value?
it will prompt you every time when you will run the report...
you have to use rank(random()). If you don't have random in FM or RS, you can add it.
So would the code look like this to give me 50 random account numbers?
rank(random([CUSTOMERNUMBER]))<51
random() ususally has no parameters.
Ok, sorry for being thick headed - I'm a newbie. If there are no parameters for random, what would the code look like to get a list of 50 random accounts? I've tried the following, but neither of them worked.
rank(random()[CUSTOMERNUMBER])<51
rank(random([CUSTOMERNUMBER]))<51
No worries, matey!
First, do you have random function available in Report Studio, meaning can you select it from the list of available functions for a DataItem calculation. If NO, please find instructions on how to add a custom database function.
Then follow with creating a calculation of this form for your filter: rank(random())<51
I think it should work.