How to set up random response from google sheet

(薛佳文) #1

My bot can do that search for a field, come to the corresponding field now .

But now I had another sheet that a column corresponds to multiple results.I wanna to ask how do I make the search results are random.

For example,I search the “ID” column for BA56, and I want to make the result is random. sometimes show M26, sometimes show B1 and sometimes show T48.

Thanks for the response!

(Daniel Beckett) #2

You could generate a random number using the Number service (between 1 and 3) and then have three different actions setup using Filters so that Result is sent IF random number = 1, Result 2 is sent if random number = 2 etc.

(薛佳文) #3

Thanks for your answer!It’s really helpful!

I still want to ask if I had many rows (almost 30), could I have another method?

(Daniel Beckett) #4

I think the only other method would be through the Code service with some custom code. I’m not sure on exactly what code you would need to use though unfortunately.