O'Reilly logo

Tableau 10.0 Best Practices by Jenny Zhang

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

String calculations

In the previous section, we talked about Date calculation. In this section, we will learn about String calculations.

Getting last name from an email

A lot of times we need to get the last name out of an email. A simple String calculation will do the work.

For example, if I want to get last name from an email address like firstName.lastname@example.com. The calculation is as follows:

Getting last name from an email

You can get the string on the left of the "@" using the LEFT function. The next step is to use the MID function to get the string from the period to the left of the "@".

Getting street number from address

For example, I want to get the street number from ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required