# HELP: How to get random data from a 'table' using 'randbetween'

#### faizzsheikh

##### New Member
I have a 2 column 'Table' with some data (alphabets not numbers). I want to generate random data from that table (column 1) into a cell.

I want to use 'Table' because when I add new data to the 'Table'... the random data will automatically consider the new data from the table.

### Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
With your data in a named range, (Name: "TABLE")
=INDEX(TABLE,RANDBETWEEN(1,ROWS(TABLE)))

If you don't want a named range
=INDEX(A:A,RANDBETWEEN(1,COUNTIF(A:A,"<>"&"")))

Last edited:
With your data in a named range, (Name: "TABLE")
=INDEX(TABLE,RANDBETWEEN(1,ROWS(TABLE)))

If you don't want a named range
=INDEX(A:A,RANDBETWEEN(1,COUNTIF(A:A,"<>"&"")))

Thanks a lot sir! You made my day!

The random generated data also includes the table 'Title', how can we exclude it?

I am using this formula: =INDEX(TABLE,RANDBETWEEN(1,ROWS(TABLE)))

The random generated data also includes the table 'Title', how can we exclude it?

I am using this formula: =INDEX(TABLE,RANDBETWEEN(1,ROWS(TABLE)))

Try this,
=INDEX(TABLE,RANDBETWEEN(1,ROWS(TABLE)-1)+1)

Replies
17
Views
375
Replies
3
Views
233
Replies
5
Views
198
Replies
11
Views
248
Replies
2
Views
941

1,212,099
Messages
6,105,958
Members
447,987
Latest member
rasika_99

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

### Which adblocker are you using?

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

### Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back