Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Google Analytics and chart

Hi all
I am using Google Analytics to get the page views for 3 websites and i have a bar chart chart with the page view.

www.123.com
www.example.com
www.ABC.com

However for one of the website, www.ABC.com, i used the landing page and used conditional column
if "landing page" contain /mysistersite/ then Subdomain else www.ABC.com/mysistersite

How do i get the chart to display:

www.123.com
www.example.com
www.ABC.com
www.ABC.com/mysistersite


I can't show the file due to the data, hope someone can advice.
Thank you.

1 ACCEPTED SOLUTION
v-eachen-msft
Community Support
Community Support

Hi @Anonymous ,

 

You could create a new column to get the result.

Column 2 =
VAR _search1 =
    SEARCH ( "/", 'Table'[Column1], 1, 0 )
VAR num1 =
    IF ( _search1 = 0, 0, _search1 - 1 )
VAR _search2 =
    RIGHT ( 'Table'[Column1], LEN ( 'Table'[Column1] ) - num1 - 1 )
VAR _search3 =
    SEARCH ( "/", _search2, 1, 0 )
RETURN
    IF ( _search3 = 0, 'Table'[Column1], LEFT ( 'Table'[Column1], num1 ) )

Here is the result for your reference.

1-1.PNG

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

View solution in original post

1 REPLY 1
v-eachen-msft
Community Support
Community Support

Hi @Anonymous ,

 

You could create a new column to get the result.

Column 2 =
VAR _search1 =
    SEARCH ( "/", 'Table'[Column1], 1, 0 )
VAR num1 =
    IF ( _search1 = 0, 0, _search1 - 1 )
VAR _search2 =
    RIGHT ( 'Table'[Column1], LEN ( 'Table'[Column1] ) - num1 - 1 )
VAR _search3 =
    SEARCH ( "/", _search2, 1, 0 )
RETURN
    IF ( _search3 = 0, 'Table'[Column1], LEFT ( 'Table'[Column1], num1 ) )

Here is the result for your reference.

1-1.PNG

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors