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

Add a new file to Source.Files with 4 additional columns previous files don't have

Hi team,

 

I am having trouble with this:

I have 13 CSV files as my power BI data source, growing on a weekly basis, but now i have 4 additional columns. How do i tell power BI that he should have let's say these 4 columns to the full dataset and populate the previous files with let's say null values.

 

thanks,

1 ACCEPTED SOLUTION

Accepted Solutions
Super User V
Super User V

Re: Add a new file to Source.Files with 4 additional columns previous files don't have

Hi @castanheiro1982

 

The best option for this is to change the file that you use as your transformation file, that way when you append the files using the custom function the columns will be filled with null.

 

You just need to edit the step Navigation on the Sample File:

 

  • Go to the Sample file
  • Source
  • Check the number of the line of the new file you want to use as new default file
  • On the navigation step change the 0 by the line number -1 that you took on the previous point
    • If line is 35 you should place 34

= Source{0}[Content]

 

    • Go to the Transform Sample file and make the necessary changes.
    • On the query file you should have the previous file with null on the additional columns

Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog:

Power BI em Português





View solution in original post

2 REPLIES 2
Super User V
Super User V

Re: Add a new file to Source.Files with 4 additional columns previous files don't have

Hi @castanheiro1982

 

The best option for this is to change the file that you use as your transformation file, that way when you append the files using the custom function the columns will be filled with null.

 

You just need to edit the step Navigation on the Sample File:

 

  • Go to the Sample file
  • Source
  • Check the number of the line of the new file you want to use as new default file
  • On the navigation step change the 0 by the line number -1 that you took on the previous point
    • If line is 35 you should place 34

= Source{0}[Content]

 

    • Go to the Transform Sample file and make the necessary changes.
    • On the query file you should have the previous file with null on the additional columns

Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog:

Power BI em Português





View solution in original post

Highlighted
Frequent Visitor

Re: Add a new file to Source.Files with 4 additional columns previous files don't have

Thank you Miguel!

 

that did the job very easily and now I learned a new option 🙂

 

Helpful resources

Announcements

August Community Highlights

Check out a full recap of the month!

Experience what’s next for Power BI

Join us for an in-depth look at the new Power BI features and capabilities at the free Microsoft Business Applications Launch Event.

Top Solution Authors