Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Adding rows with a blank column

muns
7 - Meteor

Hi everyone,

 

I am trying to figure out how to add rows to my table based on my first column (Year) but leaving my second column (X) blank?  I'm pretty sure it must be the Generate Rows tool but haven't been able to configure it correctly.

 

This is what I'm trying to achieve:

 

Before After
YearX YearX
201010 201010
201120 201120
201230 201230
201340 201340
201450 201450
   2015blank
   2016blank
   2017blank
   2018blank

 

Many thanks,

Mark

5 REPLIES 5
Jonathan-Sherman
15 - Aurora
15 - Aurora

Hi @muns,

 

You could simply join on a reference table with all years you want to appear in the data set and union:

 

image.png

 

If this solves your issue please mark the answer as correct, if not let me know! I've attached my workflow for you to download if needed.

 

Regards,

Jonathan

RolandSchubert
16 - Nebula
16 - Nebula

Hi @muns ,

 

you could identify the last entry in your existing table by a Summarize tool (using "MAX"),
create additional years (starting with last existing year until current year using the Generate Rows
tool, and use Union to get the completed table. I've attached a workflow.

 

Best regards

 

Roland

muns
7 - Meteor

Thanks Robert and Jonathan for your solutions.

 

I went with Roberts suggestion in the end as it seems more dynamic if my base data changes.

 

Much appreciated.

 

Mark

ashissanpui
9 - Comet

Add union app between two data sources. Your issue will get resolved.

muns
7 - Meteor

Apologies *Roland not Robert

Labels