cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
yippiekyoo Frequent Visitor
Frequent Visitor

Filter measure "starts with"

Hi All,

 

working currently on a project where I need to filter certain values from a database in order to categorize them. 

 

I need to have a measure that says filter all part numbers starting with the letter A. 

 

Thats my current function:

Filter function =
SUMX(
FILTER(
'AO Domestic',
'AO Domestic'[Part Number] = "STARTS WITH A"
)
,
'AO Domestic'[Total Actual Cost incl. Retro. Pay])

 

Would be great if someone could tell me how to correct the measure. Thanks a lot in advance.

 

Kind regards

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Filter measure "starts with"

Hey,

 

you can write your measure like so

Measure 3 = 
CALCULATE(
	SUM('FactWithDates'[Amount])
	,FILTER(
		'FactWithDates'
		,LEFT('FactWithDates'[Item],1) ="A"
	)
) 

Hopefully this gets you started

 

Regards

Tom

Hamburg - Germany
If I answer you question, please mark my post as solution, this will also help others.
Proud to be a Datanaut!
2 REPLIES 2
Super User
Super User

Re: Filter measure "starts with"

Hey,

 

you can write your measure like so

Measure 3 = 
CALCULATE(
	SUM('FactWithDates'[Amount])
	,FILTER(
		'FactWithDates'
		,LEFT('FactWithDates'[Item],1) ="A"
	)
) 

Hopefully this gets you started

 

Regards

Tom

Hamburg - Germany
If I answer you question, please mark my post as solution, this will also help others.
Proud to be a Datanaut!
yippiekyoo Frequent Visitor
Frequent Visitor

Re: Filter measure "starts with"

Hi thank you very much  - that works.