Home Page for the TeradataForum

Archives of the TeradataForum

Message Posted: Wed, 12 Jun 2002 @ 20:12:41 GMT

  <Prev Next>   <<First <Prev Next> Last>>  

Subj:   Re: Creating months table
From:   Dieter Nöth

create table MyMonthCalendar as (
  calendar_date - extract(day from calendar_date) + 1 as StartOfMonth
  ,calendar_date as FourthThursday
from sys_calendar.calendar
where weekday_of_month = 4
and day_of_week = 5
and year_of_calendar between 1999 and 2099
) with data unique primary index (StartOfMonth) ;

If you don't run V2R4 then create the table and insert/select...


  <Prev Next>   <<First <Prev Next> Last>>  
  Top Home Privacy Feedback  
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 28 Jun 2020