cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
miguelHG
Frequent Visitor

Crear medidas por características de articulo

Buen Día a Todos,

Espero me puedan ayudar con este tema que no he podido resolver, sobra decir que apenas estoy aprendiendo a usar power bi, pero en este caso no he encontrado una solución 100% correcta. Tengo una tabla de artículos y cada uno de los items tiene más de 50 caracteristicas que están en columnas, carct1, caract2, etc, pero necesito sacar la venta según las caracteristicas, ya que en unos articulos, la caract9 es "llanta", carcact25 es "SUB", entonces, me piden la venta de todas las llantas, (caract9) y de ahí, un sub arbol para poder ver unicamnete las de SUB, espero haberme explciado, Gracias.

2 REPLIES 2
miguelHG
Frequent Visitor

Thanks @amitchandak, it is a complicated subject, that's why I ask for your support, I have tried

"IF (HASONEVALUE ('Table' [ ]), SWITCH (VALUES ()"

, but I thought there should be a simpler way, with DAX. The table that contains this information is that of items, but I have others that contain all the sales and inventory operations, etc., I don't know if it is feasible to unpivot that table.

amitchandak
Super User IV
Super User IV

@miguelHG , Not able to get it completely. What I got is; say the tire is characteristic 9 for one item and can be characteristic 25 for another. If this is the case you need data normalization. Means you put the same character in the same column.  That could be a lot of work and need a lot if-else or switch.

 

Another way is you unpivot all these columns, so you will only one characteristic column. But this means 50-times data and you need to handle formula's not to duplicate the count and sums.

 

https://radacad.com/pivot-and-unpivot-with-power-bi
https://www.youtube.com/watch?v=2HjkBtxSM0g



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

Helpful resources

Announcements
PBI User Groups

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

April Update

Check it Out!

Click here to read more about the April 2021 Updates!

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.

secondImage

Experience what’s next for Power BI

See the latest Power BI innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors