1 Reply Latest reply on Feb 27, 2017 1:54 PM by Jim Dehner

# How can I get a calculated column from a formulated variable?

I am trying to create two calculated columns, one for total count and one that's a percentage of the total lines based on that total count.

I am needing to count a formulated variable that I created which is this:

[Tag] =If([Shp not Inv]=2 And [Less than today]=1 And [Held Code]<>"T1") Then "1"

ultimately, it provides a 1 on lines of the orders that meet these three criteria. I can change it to be =If([Shp not Inv]=2 And [Less than today]=1 And [Held Code]<>"T1") Then 1, which makes it a Numeric Measure, or by leaving it as it is, it stays a String Measure, either way, when I try to count the rows with a 1 applied to them I get the #MULTIVALUE error.

I have tried several different formulas, such as:

=Count([Order Number]) Where([Shp not Inv]=2 And [Less than today]=1 And [Held                  Code]<>"T1")

&

=Count ([Order Number];Distinct) Where ([Tag] = "1";[Tag])

&

=Count([Tag])

• ###### 1. Re: How can I get a calculated column from a formulated variable?

Kyle

Not sure I'm following you - but if you have the statement that will place a numeric 1 in the records you want to count - could you just use a window_sum calc like this one - I just took super sore and did an If (like your numeric version) that determined if monthly sales exceeded 10,000 then used window_sum to total them.

Let me know if that helped

Jim