Can someone help me with the code below? What I need is the number of the day of the week from the report_dt field so I can use it to do some aggregations later. Basically, if its a monday, give me 1. the data in the report_dt field is in a date format (1/1/2012) etc.
I know how to do this via MySQL but the closest thing I can figure out in Netezza is:
SELECT date_part('day',report_dt) as report_dt
FROM table
which gives me the day of the month.
thanks for any help