How to do timestampadd on month column if the month is 'YYYYMM'?
YalaMar 9 2011 — edited Mar 10 2011Hello
I have a quick question about using the timestampadd function to get 12 months prior to the month column.
I have a month column which is Nvarchar type and the data in it takes the format of 'YYYYMM'..
So i tried doing substring on month column and then putting it in timestampadd.
It goes like: Timestampadd(sql_tsi_month, -12, SUBSTRING("Monthly Period"."Fiscal Period" FROM 7 FOR 2) ). I had to use it in expression builder and I was getting the error:[nQSError: 22025] Function TimestampAdd is called with an incompatible type.
Any ideas?
Thanks