cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper I
Helper I

Creación de una tabla de fechas con solo meses y años

Hola quiero crear una tabla de fechas con el siguiente formato:

MES : formato número entero (1-12)

Año: año de inicio: a partir de dos cuadros f_final y f_mvt, columna fuente Número entero

Fecha completa : 1er día de cada mes ex 01/01/2014 , 01/02/2014 ...

ID_DATE: Año*100+MES

Gracias

1 ACCEPTED SOLUTION
Super User II
Super User II

@adnane_k

tal vez usted puede probar esto

Table = 
VAR TBL=ADDCOLUMNS(CALENDARAUTO(),"month",month(''[Date]),"year",year(''[Date]),"ID_Date",year(''[Date])*100+month(''[Date]),"fulldate",date(year(''[Date]),month(''[Date]),1))
RETURN SUMMARIZE(TBL,[month],[year],[ID_Date],[fulldate])

1.PNG





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

1 REPLY 1
Super User II
Super User II

@adnane_k

tal vez usted puede probar esto

Table = 
VAR TBL=ADDCOLUMNS(CALENDARAUTO(),"month",month(''[Date]),"year",year(''[Date]),"ID_Date",year(''[Date])*100+month(''[Date]),"fulldate",date(year(''[Date]),month(''[Date]),1))
RETURN SUMMARIZE(TBL,[month],[year],[ID_Date],[fulldate])

1.PNG





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

Helpful resources

Announcements
secondImage

Congratulations!

We are excited to announce the Power BI Super Users!

Wave Release 2

Check out the updates in Power BI.

Overview of Power BI 2020 release wave 2!

Get Ready for Power BI Dev Camp

Get Ready for Power BI Dev Camp

Mark your calendars and join us for our next Power BI Dev Camp!.

secondImage

The largest Power BI virtual conference

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