5 Replies Latest reply: Feb 23, 2012 7:40 AM by Sunil Chauhan RSS

    Adding Columns which don't contain values

      Dear Community,


      I've some rather easy looking question about the script and adding columns.


      I've got a monthly export with all aggregated sums per KPI in the columns


      So for 3 months until march it looks like this:


      column A is Department

      column B is KPI

      column C is 1

      column D is 2

      column E is 3


      The number stands for the month and that's exactly my problem. The column is only existing, if it contains values.

      I want to upload the table in this format:


      column A is Department

      column B is KPI

      column C as Jan

      column D as Feb

      column E as Mar


      This runs pretty well, but the problem occurs if one month is added in the export-file ("4"). I either can't upload it, because i don't have any values (=column doesnt exist) or the alias (e.g. "Apr" for "4") isn't party of the script.


      So how do i automatically count the columns which have values and corresponding to that give fixed names to the column, even if it doesn't contain any values?


      Thanks in advance,