# Can I increment a parameter in my expression?

I am calculating some columns and I need to increment a parameter by 1 for every new column, is that possible?
Like I create a parameter with date 01/01/2017 and in my calc. I just do
(xy - {date]+1)
(xy - {date]+2)
(xy - {date]+3)

and so on…

It sounds like you’re performing some calculations in a matrix table. Usually, it’s better to perform calculations when the data is presented as a straight table, and only pivot it into a matrix table as the last step. If it was a straight table then incrementing the parameter would be done by rows which is as simple as adding a row number (e.g. generated by Enumerate transformation).

Incrementing by columns is not possible at this moment.

1 Like

I am not very familiar with EasyMorph yet but I am learning
Can you show me what would be the best way calculating columns for each month with a calculaton like this

if(not isempty([Project / Service Start Date]) and not isempty([Project / Service End Date]),
if(makedate(2017, 2, 1) >= [Project / Service Start Date] and makedate(2017, 2, 1) <= [Project / Service End Date], [FTE], 0),
if(isempty([Project / Service Start Date]) and isempty([Project / Service End Date]), 0,
if(isempty([Project / Service Start Date]) and makedate(2017, 2, 1) <= [Project / Service End Date], [FTE], 0)))

the logic behind this is less relevant but the makedate() part, I have 12 Columns with the same calculation and I have to replace the month value for each… this is frustrating =)

Can I do this with a helper table or something similar?