How to change the data type in Looker Studio?

How to change the data type in Looker Studio?

How do you change the data type in Looker Studio?

Looker Studio can manage many field types. Each one has its own specific options, and you can always find a way to display your data in the format you wish.

We will see how to change the data type fields and the possibilities here.

Data Type list:

  • Numeric
    • Number -> floating point number
    • Percent -> floating point number representing a ratio.
    • Currency -> floating point number representing a financial value (please note that Looker Studio won't do the conversion, only modify the currency symbol).
  • Text -> numbers, letters, characters, or symbols.  
  • Date & Time -> a calendar date.
  • Boolean -> logical value returning TRUE or FALSE.
  • Geo -> a geographic region (ISO code, country name, latitude, and longitude)
  • URL
    • URL -> a web address
    • Image -> An image.

How to modify the data type?

There are two ways to modify your data type. 

The first one is in a chart. The data type you applied on a metric will only exist for this chart.

The second is in the data source and will be applied to every chart using the metric you configured.

In a chart:

Click on a chart and open the field option.

You can select a new data type in the associate dropdown:

Change data type for a field in Looker Studio.

You can also provide more information about the display option in the Display Format dropdown.

For example, for numbers, you can choose the numbers of decimal. For date, you can choose which format to use precisely.

Change the display format for a field in Looker Studio.

And by clicking the Custom format link, you can find more options to fits your need.

Here is the custom date format option:

Define precisly your date format in Looker Studio.

From a data source:

Open your data source field list -> Resource -> Manage added data source -> Edit your source (if this does not lead you to a field list, clicks on Field list at the top right of the screen after editing your data source).

Locate the Type column. Here, you can change the data type for a given field.

Type column in your Looker Studio data source.

All charts using this field will be updated with the new configuration. 

You cannot manage Display Format in the data source as we did in the chart.

Warning: if your data source is reusable, you are modifying the data type for a metric across all reports using this data source.

More function to use with Looker Studio

DATETIME
:
How to use the DATETIME function
REGEXP_EXTRACT
:
Mastering REGEXP_EXTRACT Function in Looker Studio: A Comprehensive Guide for Effective Data Extraction and Manipulation
TAN
:
Understanding the TAN Function in Looker Studio: Features, Syntax, Practical Applications, Limitations, and Tips for Optimal Usage
AVG
:
Introduction to AVG Function in Google Data Studio
DATETIME_SUB
:
Mastering the DATETIME_SUB Function in Looker Studio: A Guide to Manipulate Date and Time Information in Your Datasets