I've got a database (2000) with 12 tables - one for each month (rolling 12).
I've got an ugly gob of dynamic SQL to get the job done of totalling for the last 12 (loop through temp table with tablenames + processed flag), but would LOVE to replace it with non-dynamic SQL.
Any ideas? I mean other than tracking down the genius who came up with this implementation and beating him/her to within an inch of his/her life?
< M!ke >
I've got an ugly gob of dynamic SQL to get the job done of totalling for the last 12 (loop through temp table with tablenames + processed flag), but would LOVE to replace it with non-dynamic SQL.
Any ideas? I mean other than tracking down the genius who came up with this implementation and beating him/her to within an inch of his/her life?
< M!ke >