I am trying to set a variable:
SET JANRETENSION = B201;
(I tried it will as SET JANRETENSION = 'B201' as well and it didn't work either)
But when I use it in my where clause it is not recognized.
Here is the script followed by the error message:
ProductionByDeptByCust:
Load
[Dept] as [Temp Dept],
sum([Commission]) as [Temp Commission Dept]
Resident Production
Where
ProdGLMonthOrig <= $(JANRETENSION)
and
ProdGLMonthOrig >= $(JANRETENSION)
and
Dept<>'4'
Group By [Dept]
Order by Dept ASC;
Error MESSAGE I am getting:
Field not found - <B201>
ProductionByDeptByCust:
Load
[Dept] as [Temp Dept],
sum([Commission]) as [Temp Commission Dept]
Resident Production
Where
ProdGLMonthOrig <= B201
and
ProdGLMonthOrig >= B201
and
Dept<>'4'
Group By [Dept]
Order by Dept ASC
You have to use it this with single quotes:
ProdGLMonthOrig <= '$(JANRETENSION)'
and
ProdGLMonthOrig >=' $(JANRETENSION)'
You have to use it this with single quotes:
ProdGLMonthOrig <= '$(JANRETENSION)'
and
ProdGLMonthOrig >=' $(JANRETENSION)'