in reply to Logic problem on loops
I'm suspicious of the DISTINCT in that second SELECT. Are you really sure you're gettin back the data you want?
Without knowing more about the data, it's hard to know whether you have a problem tripping the month tests multiple times. I suggest adding
and so on for the other months. This will tell you whether you're accidentally tripping those tests multiple times, and clobbering counters.if ($month eq "1") #January, obviously { >>> $message .= "<!-- January -->\n";
|
|---|