I have a set of n
ids, say table 1, like so:
id |
---|
id_1 |
id_2 |
... |
id_n |
I would like to combine this with a set of numbers 1...m (m is medium large here, i.e. between a hundred and a thousand) to get a table that looks like this:
id | number |
---|---|
id_1 | 1 |
id_1 | 2 |
... | ... |
id_1 | m |
id_2 | 1 |
... | ... |
id_2 | m |
... | ... |
id_n | m |
That is the size of this, say table 2, is going to be m*n.
Is something like this possible in SQL? The dialect I am using is Snowflake.