What's wrong with declaring a cursor?
-------------------------------------------------------
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
go
ALTER procedure [dbo].[spTableStats] as
/* ---------------------------------------------------------------------------------------------------------
This code, for the current database, lists info about each of its tables:
name, row count, column count,...