Forum Discussion

harsha449's avatar
harsha449
Frequent Visitor
8 years ago

PATHITEM function to extract string from the URL

Hi,

 

I'm trying to extract string from the URL using PATHITEM function, it is working fine for DAX when the data is in excel.

 

Now I'm connect to direct query, i need to use DAX formula compatibilty in DirectQuery mode.

 

https://docs.microsoft.com/en-us/sql/analysis-services/tabular-models/dax-formula-compatibility-in-directquery-mode-ssas-2016?view=sql-analysis-services-2017

 

Example:

 

URL: /country/english/pages/careers/article

 

I want to extract "careers" in new column.

 

DAX formula is working fine: PATHITEM(SUBSTITUTE(COLUMN,"/","|"),5)

 

Could you please help me with the function to do the same for direct query

 

Thanks

7 Replies