From: NZDeveloper on
I have an expression in a view that calculates a date by adding a
number of months using the dateadd function.

I want to get both the datepart (m for month in my caase) and hte
number (1-3 months) from other fields in my view.

I've tried this
DATEADD(dbo.tbl_PTDF_PreTreatDevFrequency.PTDF_DateAddInterval, -

but it bomb out with I try and run it with the following error:

"dbo.tbl_PTDF_PreTreatDevFrequency.PTDF_DateAddInterval is not a valid
dateadd option"

The field dbo.tbl_PTDF_PreTreatDevFrequency.PTDF_DateAddInterval holds
a text value of 'm'

If I replace the datepart with m, it works, why cant I pass my value
from dbo.tbl_PTDF_PreTreatDevFrequency.PTDF_DateAddInterval ?

Thanks in advance


Pages: 1
Prev: SSIS Developer / CA
Next: Advice on replication