I didn't find it on the documented date time functions here https://drill.apache.org/docs/date-time-functions-and-arithmetic/
On Mon, Feb 8, 2016 at 12:09 PM, Sudip Mukherjee <[email protected]> wrote: > Hi, > Are TIMESTAMPADD / TIMESTAMPDIFF functions supported through drill? I am > getting an error while running the below query > > SELECT CAST(EXTRACT(YEAR FROM CAST({fn > TIMESTAMPADD(SQL_TSI_YEAR,CAST(`myshare`.`mtm` AS INTEGER),{d > '1970-01-01'})} AS DATE)) AS INTEGER) AS > `yr_Calculation_IGIAGIIHHFEBCCIFEE_ok` > FROM `dfs.data`.`MyFileShare_2214` `myshare` > GROUP BY CAST(EXTRACT(YEAR FROM CAST({fn > TIMESTAMPADD(SQL_TSI_YEAR,CAST(`myshare`.`mtm` AS INTEGER),{d > '1970-01-01'})} AS DATE)) AS INTEGER) > > > VALIDATION ERROR: From line 3, column 55 to line 3, column 66: Column > 'SQL_TSI_YEAR' not found in any table > > Thanks, > Sudip > > > > ***************************Legal Disclaimer*************************** > "This communication may contain confidential and privileged material for > the > sole use of the intended recipient. Any unauthorized review, use or > distribution > by others is strictly prohibited. If you have received the message by > mistake, > please advise the sender by reply email and delete the message. Thank you." > **********************************************************************
