Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Add New colum

Hi everybody,

I have 2 Tables " PontoB" and "TURNO"


And


I need add the colum "Escala" from "Turno" on the other table "PontoB".

It´s only add new colum in "PontoB"

Here the relationship

 







 

  • Hi Anonymous 

     

    Your model does not seem to be very friendly, please consider optimising the model structure, with loops, then cross filtering can create an ambiguous set of relationships.please consider star model or set cross filter direction to both. Refer this article.

     

    And in your case , maybe you can try some measures like the following:

    Escala from TURN0 = CALCULATE(FIRSTNONBLANK('TURNO'[Escala],0),RELATEDTABLE(TURNO))

     

    If it do not work please provide pbix file without sensitive data.

     

     

    Best Regards

    Community Support Team _ chenwu zhu

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

6 Replies

  • Hello there Anonymous ! You can do this in Power Query with the "Merge Queries" option. Open PQ and in the "Home" tab you have the "Merge Queries" option in the "Combine" Folder. In the pop-up window, select the two tables to merge:  " PontoB" and "TURNO". Then, in each one, while holding the CTRL button, select the "Data" and (I think you can also use this column as a connection) the "TIME" column (similar to what I need in the following print).

     

     

    Afterwards, open the icon "Expand" icon in the newly created column and unselect all columns except for the "Escala" and press "Ok" like in the example print.

     

     

    And then verify that the data was correctly merged!

     

    Hope this answer solves your problem!
    If you need any additional help please @ me in your reply.
    If my reply provided you with a solution, please consider marking it as a solution ✔️ or giving it a kudoe 👍
    Thanks!

    You can also check out my LinkedIn!

    Best regards,
    Gonçalo Geraldes

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi goncalogeraldes,

      Thank´s for your help

      I did, but the value show with null



      I merge date with date, it´s the factor comum

       




    • Anonymous's avatar
      Anonymous
      Not applicable

      The colum TIME it´s calculate in PontoB


      From table "Colaboradores"