Category / Section
How to Convert date in String to Date type in Bold BI
Published:
Converting a string data type to a date type is a common requirement when working with data in Bold BI. This can be achieved through column data type conversion or by creating an expression based on the datastore being used.
Column Data Type Conversion
- In Bold BI, navigate to the Data Source tab.
- Edit the Data Source.
- Choose the desired data type (in this case, Date) and apply the changes.
For more information, refer to the Bold BI documentation on handling column type conversion.
Creating an Expression
You can also create an expression in Bold BI to convert the column into a timestamp with a specified format. The expression will vary based on the datastore you are using.
Postgres
Expression: TO_TIMESTAMP([datestring_col], 'DD/MM/YYYY')
MS SQL
Expression: convert(datetime,[datestring_col], 103)
Replace [datestring_col]
with the name of the column containing the string data you want to convert to a date.