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

How to create data to column from existing table

I can get this kind of data. Data contains thousands rows. My need is get to actual factory column to all rows 0008. and other factory.  This is easy to do to those rows where at Production area column, there is KANK term available.

Actual Factory = IF(ISNUMBER(SEARCH("KANK";ZMDWF[Production area];;BLANK()));"0008")

 

but how I can get this 0008 to each rows?

 

Capture.PNG

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-jiascu-msft Super Contributor
Super Contributor

Re: How to create data to column from existing table

Hi @TimoKosonen,

 

So what are the rules? You can add it yourself. Then the [Actual factory] will be filled automatically.

 

Factory =
SWITCH (
    TRUE (),
    ISNUMBER ( SEARCH ( "Kank", 'ZMDWF'[Production area],, BLANK () ) ), "0008",
    ISNUMBER ( SEARCH ( "oth", 'ZMDWF'[Production area],, BLANK () ) ), "0001",
    "9999"
)

 

Best Regards,
Dale

Community Support Team _ Dale
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

7 REPLIES 7
Super User
Super User

Re: How to create data to column from existing table

@TimoKosonen Please post the sample data (which is easy to copy and paste) to solve your issue quickly.



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

Proud to be a Datanaut !





v-jiascu-msft Super Contributor
Super Contributor

Re: How to create data to column from existing table

Hi @TimoKosonen,

 

There is only one "KANK***" in the data. How can we get "0008" to each row? Which rows? All the rows?

Is there only one condition or requirement? 

Please provide a DUMMY sample file that we can download.

 

 

Best Regards,
Dale

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

Re: How to create data to column from existing table

Below there is data example. All same SD doc numbers need to be manufactured at same factory.  Hopefully this helps.

Data example is .pbix file. 

 

Power BI data example

 

 

Super User
Super User

Re: How to create data to column from existing table

Confusing question.  What exact result do you want.

v-jiascu-msft Super Contributor
Super Contributor

Re: How to create data to column from existing table

Hi @TimoKosonen,

 

Is the result in the snapshot what you want?

Actual Factory =
CALCULATE ( MIN ( [Factory] ), ALLEXCEPT ( ZMDWF, ZMDWF[SD Doc.] ) )

How_to_create_data_to_column_from_existing_table

Best Regards,
Dale

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

Re: How to create data to column from existing table

This is partial solution. how I can add other factory?  Please look picture what is need to me,

 

example.PNG

 

 

 

v-jiascu-msft Super Contributor
Super Contributor

Re: How to create data to column from existing table

Hi @TimoKosonen,

 

So what are the rules? You can add it yourself. Then the [Actual factory] will be filled automatically.

 

Factory =
SWITCH (
    TRUE (),
    ISNUMBER ( SEARCH ( "Kank", 'ZMDWF'[Production area],, BLANK () ) ), "0008",
    ISNUMBER ( SEARCH ( "oth", 'ZMDWF'[Production area],, BLANK () ) ), "0001",
    "9999"
)

 

Best Regards,
Dale

Community Support Team _ Dale
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

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 232 members 2,324 guests
Please welcome our newest community members: