This script has the advantages of being fast and not having any dependencies to existing tables so it can easily be used to generate a tally table, or a set of dimension keys. It becomes especially useful when used as the left part of a join (to control cardinality) or the left part of a cross apply (to replace a while loop for instance).
2013-08-22
17,075 reads