I recently had the need to SELECT some data from MySQL tables and include a “rownum” column on each row. For example, I needed some results that looked like this: id rownum name 1234 1 Billy 8274 2 Carl 4352 3 Dave Notice that I cannot use the “id” column because it is auto-generated, and…