Correct quoting.

This commit is contained in:
Andrew McMillan 2008-10-27 14:37:11 +13:00
parent 9683df685b
commit be3f2ab3e3

View File

@ -182,10 +182,10 @@ BEGIN
loopcount := 100; -- Desirable to stop an infinite loop if there is something we cannot handle loopcount := 100; -- Desirable to stop an infinite loop if there is something we cannot handle
LOOP LOOP
-- RAISE NOTICE ''Testing date: %'', our_answer; -- RAISE NOTICE ''Testing date: %'', our_answer;
IF frequency = 'DAILY' THEN IF frequency = ''DAILY'' THEN
IF byday IS NOT NULL THEN IF byday IS NOT NULL THEN
LOOP LOOP
dow = substring( to_char( our_answer, 'DY' ) for 2); dow = substring( to_char( our_answer, ''DY'' ) for 2);
EXIT WHEN byday ~* dow; EXIT WHEN byday ~* dow;
-- Increment for our next time through the loop... -- Increment for our next time through the loop...
our_answer := our_answer + (length::text || units)::interval; our_answer := our_answer + (length::text || units)::interval;