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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Andrea78m
Frequent Visitor

Listing data by date

Cattura.PNG

Hi, when I connect a SQL server into Power BI, the date field(set as yyymmdd, es 20180102) becomes a SUM.

 

Pls can you help me?

How can I change it and to have it like a date, and not like a sum of numbers?

 

 

 

1 ACCEPTED SOLUTION

Hi @Andrea78m,

 

Add a new calculated column.

Column2 =
LEFT ( Table2[Column1], 4 ) & "/"
    & RIGHT ( LEFT ( Table2[Column1], 6 ), 2 )
    & "/"
    & RIGHT ( Table2[Column1], 2 )

1.PNG2.PNG3.PNG

 

Best regards,

Yuliana Gu

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

View solution in original post

3 REPLIES 3
v-yulgu-msft
Microsoft Employee
Microsoft Employee

Hi @Andrea78m,

 

I think the date values which is formatted as "20180102" is recognized as whole number. The highlighted symbol ponits that the data type is number. So, please change the data type to "Date" in the ribbon.

1.PNG

 

Best regards,

Yuliana Gu

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

1.PNG2.PNG

 

Unfortunately it gives me error

Maybe I'd modify the query in power BI?

Do you habe others idea to solve it?

Hi @Andrea78m,

 

Add a new calculated column.

Column2 =
LEFT ( Table2[Column1], 4 ) & "/"
    & RIGHT ( LEFT ( Table2[Column1], 6 ), 2 )
    & "/"
    & RIGHT ( Table2[Column1], 2 )

1.PNG2.PNG3.PNG

 

Best regards,

Yuliana Gu

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

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.