• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

fill empty cells if condition is met

cito

New Member
Hi,

Best to look at attached file for explanation of problem.
This is most likely ridiculously easy to figure out, but it escapes me, and I'd very much appreciate the help.

In short:

Two rows (or three, or four) contain identical serial numbers

One of the rows contains a cell with a value in it (in attach image it's LIJN 3)

If the rows containing the identical serial numbers have no value in the cell, then the value from the row (with identical serial number) that DOES contain a value should be copied.

In Powerquery, I can add a index column 1; index column 0, merge queries and expand only relevant column, but this is not the right solution for this case I think.

I'd like to automate this... and it might well be that I have a number of files that do not have any "empty" cells..

Any help would be greatly appreciated,

If possible, feel free to reply to citogrid@gmail











problem.jpg
 
With PQ you can fill up and down, since data seems sorted, it's ver y easy to do. I do not see a reason why you'd need to use an index for such task.
Perhaps best to upload a sample file, because this picture does not reveal all what needs to be considered.

Code:
let
    Source = Excel.CurrentWorkbook(){[Name="Table1"]}[Content],
    #"Filled Up" = Table.FillUp(Source,{"Column2"})
in
    #"Filled Up"
 
Last edited:

cito

Please reread Forum Rules - those are for You too:
  • Cross-Posting. Generally, it is considered poor practice to cross post. That is to post the same question on several forums in the hope of getting a response quicker.
  • If you do cross-post, please put that in your post.
  • Also if you have cross-posted and get an Solution elsewhere, have the courtesy of posting the Solution here so other readers can learn from the answer also, as well as stopping people wasting their time on your answered question.
 

cito

Please reread Forum Rules - those are for You too:
  • Cross-Posting. Generally, it is considered poor practice to cross post. That is to post the same question on several forums in the hope of getting a response quicker.
  • If you do cross-post, please put that in your post.
  • Also if you have cross-posted and get an Solution elsewhere, have the courtesy of posting the Solution here so other readers can learn from the answer also, as well as stopping people wasting their time on your answered question.
Apologies, was unaware of the decorum. Will pay better attention in future
 
Back
Top