Forum Discussion

ryan_b_fiting's avatar
ryan_b_fiting
Icon for Post Patron rankPost Patron
6 years ago

Combining Files from Folder that have differnt Headings

Hello Community - 

 

I have a bit of an urgent issue.  I have a file in my Sharepoint folder that I am connected to that the columns are shown below (but go all the way thru March 2020):

Geography	Product	Week Ending 03-31-19	Week Ending 04-07-19	Week Ending 04-14-19	

 

I am adding a new file to the folder with the recent dates (April 2020) and the column headers do not match up so I am unable to combine the files currently.  Is there an easy solution for this so that I can combine the files whenever a new one is loaded to the folder without having to do anything manually?

 

Thanks for your help everyone!

Ryan F

5 Replies

  • Mariusz's avatar
    Mariusz
    Icon for Community Champion rankCommunity Champion

    Hi ryan_b_fiting 

     

    You can Unpivot all your Week Ending columns, this would create two columns instead Attributes with eg. Week Ending 04-07-19 text as row value + Value Column with a relevant Value.

     

    Best Regards,
    Mariusz

    If this post helps, then please consider Accepting it as the solution.

    Please feel free to connect with me.
    LinkedIn

     

     

    • ryan_b_fiting's avatar
      ryan_b_fiting
      Icon for Post Patron rankPost Patron
      I have tried this already, and unfortunately this does not work for me. If I unpivot prior to promoting the first row to headers, the week ending dates show up in the values column with other values.  But if I unpivot after promoting the headers, the when I try to update the data I get an error combining the files.
      I have attached a screen shot and a sample set of data for what the data looks like.
      Thanks for the help!
       
      GeographyProductDollar SalesDollar SalesDollar SalesDollar SalesUnit SalesUnit SalesUnit SalesUnit SalesDollars per Store SellingDollars per Store SellingDollars per Store SellingDollars per Store SellingTotal Points of DistributionTotal Points of DistributionTotal Points of DistributionTotal Points of Distribution
      GeographyProductWeek Ending 03-29-20Week Ending 04-05-20Week Ending 04-12-20Week Ending 04-19-20Week Ending 03-29-20Week Ending 04-05-20Week Ending 04-12-20Week Ending 04-19-20Week Ending 03-29-20Week Ending 04-05-20Week Ending 04-12-20Week Ending 04-19-20Week Ending 03-29-20Week Ending 04-05-20Week Ending 04-12-20Week Ending 04-19-20
      Region 1Product19819.869419.139367.749538.39197118891879191213.6957601113.1920588213.0288456213.2477638972.6963799172.2012302171.859908372.19654174
      Region 2Product2238.12231.63139.3693.89908547295.4118181826.0955263164.8055172414.0821739133.8917250863.4234653412.723546272.010795215
      Region 1Product34715.434421.564649.285050.896190194410168.9138563339.0052138499.4690020379.58406072155.1380846551.3482278551.0100563555.61746743
      Region 1Product4165.28164.59102.2970.5646436264.3494736845.14343755.3836842114.1470588243.3381738722.6549282111.6870457721.356103879
      Region 2Product52.19   1   2.19   0.11950019   
      Region 1Product66912.756300.085648.687061.43139012631132147511.06049.9842789229.75592400710.5868515764.0761089163.8644145859.3389216567.01302874
      Region 2Product77246.496666.645968.047780.79145313361196161910.672297510.3519254710.0134899311.1632568168.7347587765.1217262860.0415304670.60619282
      Region 1Product85056.684854.034605.775200.77101797592310859.4341044789.2634160319.2671428579.81277358556.5501380755.0512997152.267033755.58772427
      Region 1Product95818.385001.55134.716794.6311711005102914239.5539901489.0443037978.88358131510.5017465262.0208141256.176762259.2031344265.52898394
      Region 2Product105260.495184.614486.015817.741058103989912289.5645272739.3585018058.7960980399.45973983757.4244963657.9224546853.8223342864.14734983
  • Greg_Deckler's avatar
    Greg_Deckler
    Icon for Community Champion rankCommunity Champion

    Maybe if you do not promote your headers and work with the default column names. ImkeF  and edhans might have some suggestions.