Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Not applicable

How to Capitalize only the Initial letters in DAX

I have an Existing Column in the Model with Datatype TEXT. I need to create a Calculated Column with Intial Letter as Capital... Is that possible in DAX...? If so How to do that...?

I have row like : "JUST for An example"   ---- Need not to be only 4 words, they might be in between 1 and 6

I need the row to be look like this : "Just For An Example"... I want Intial letter of every word to be Capital....


Super User
Super User

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.!AiUZ0Ws7G26Rh3tzJxjI9HhvZjDF?e=UjDUjZ

Screen Capture #1075.png

Frequent Visitor

This work for my: Thanks @Anonymous 

your way not possible to convert text to number, on the finish is better get only 2 letters, below full code for calendar table:

>> "MêsCurto", UPPER(LEFT(FORMAT([date],"MMM"),1)) & right(FORMAT([date],"MMM"), 2),


dCalendario = 
var dataminima1 = FIRSTDATE(Table[Data transação])
var dataminima2 = FIRSTDATE(Table[Data Vencimento])
var dataminima3 = FIRSTDATE(Table[Data pagamento])
var dataminima4 = FIRSTDATE(Table[Competência])
var datamin1 = MIN(dataminima1,dataminima2)
var datamin2 = MIN(dataminima3, dataminima4)
var datamin = MIN(datamin1,datamin2)
var datamaxima1 = LASTDATE(Table[Data transação])
var datamaxima2 = LASTDATE(Table[Data Vencimento])
var datamaxima3 = LASTDATE(Table[Data pagamento])
var datamaxima4 = LASTDATE(Table[Competência])
var datamax1 = MAX(datamaxima1,datamaxima2)
var datamax2 = MAX(datamaxima2, datamaxima3)
var datamax = MAX(datamax1,datamax2)


ADDCOLUMNS (CALENDAR(datamin, datamax),
"Data", FORMAT ( [date], "DD/MM/YYYY" ),
"Dia", FORMAT ( [date], "DD" ),
"Mês", FORMAT ( [date], "MM" ),
"DateAsInteger", FORMAT ( [date], "YYYYMMDD" ),
"Ano", YEAR ( [date] ), "MonthNo",  FORMAT ( [date], "MM" ), 
"AnoMesNum", FORMAT ( [date], "YYYY/MM" ), 
"AnoMes", FORMAT ( [date], "YYYY/mmm" ), 
"MêsCurto", UPPER(LEFT(FORMAT([date],"MMM"),1)) & right(FORMAT([date],"MMM"), 2),
"MêsLongo",  FORMAT ( [date], "mmmm" ), 
"SemanaNum", WEEKDAY ( [date] ), 
"SemanaDia", FORMAT ( [date], "dddd" ), 
"SemanaDiaCurto", FORMAT ( [date], "ddd" ), 
"Trimestre", "T" & FORMAT ( [date], "Q" ), 
"AnoTrimestre", FORMAT ( [date], "YYYY" ) & "/T" & FORMAT ( [date], "Q" ))


Resolver I
Resolver I

you cant do that in 1 operation

1) Lowercase all

2) split column by 1 characther (only 1 split)

3) Capital all in first colum (containing only 1 char)

4) merg the two columns

Regular Visitor

You have to use some workaround solution. When you have this kind of requirement, break that into smaller pieces and resolve those pieces one by one. Ultimately you can consolidate those solutions to get your final answer. 


Selected Month is like "FY23 M04 AUG" (Financial Month). So, this variable has "JAN", "FEB" but following DAX change "JAN" as "Jan", "FEB" as "Feb" etc...


Concatenate( Left(Right(_Selected_Month, 3 ),1),
Concatenate( Lower(Right(Right(_Selected_Month, 3 ),2)),
var _Consolidate_Report_Heading =
Concatenate( "Macro & Micro Metrics - Supplier ( ",
Concatenate( Left(Right(_Selected_Month, 3 ),1),
Concatenate( Lower(Right(Right(_Selected_Month, 3 ),2)),
Concatenate( " MOR snapshot ) as of ",
Calculate( Max( 'Last Refreshed Date'[Date Last Refreshed] ))))))
Not applicable

Try this out:



UPPER(LEFT([your_string];1)) & right([your_string]; len([your_string])-1)
Advocate I
Advocate I

I don't think this question was answered properly according to the title of the question (in DAX, not in PowerrBi user interface). 


I am using measure and would like to capitalize the word, but UPPER function makes all the letter in the word capital.  


What is the proper way to capitalize a single word (not values in a column) using DAX language in PowerBi? 

Not applicable

Hi @Anonymous,


Why not use Power Query / M to do this task? There is a quick and simple way to achieve that by using lowercase + Capitalize Each Word transformations.


Format transformations in Power QueryFormat transformations in Power Query




Not applicable

I am importing the table directly from SQL Server to SSAS Tabular model and then to Live connected Power BI so I have to Capitalise Initials in SSAS tabular model by using DAX...

@Anonymous wrote:

I am importing the table directly from SQL Server to SSAS Tabular model and then to Live connected Power BI so I have to Capitalise Initials in SSAS tabular model by using DAX...


AFAIK, there's no such existing function to do that in DAX. You may do the trick when importing from SQL Server via T-SQL. See some this demo and this.

Not applicable


Helpful resources

PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors