In Teradata SQL, is it possible to get multiple elements like the minute and second or year and date from a date/timestamp using extract? Like the line below but actually works?
select extract(minute, second from timestamp ‘2024-06-05 00:12:48’);
I have tried a bunch of different operators like and, &, &&, _, etc and none of them work.
Otherwise what would the difference be between using YEAR(TIMESTAMP ‘2024-06-05 00:12:48’) and DAY(TIMESTAMP ‘2024-06-05 00:12:48′) versus EXTRACT (YEAR FROM TIMESTAMP’2024-06-05 00:12:48′) and EXTRACT (DA YFROM TIMESTAMP’2024-06-05 00:12:48’)?
user25453037 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.