Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
ALTER.NEXT:

Join us on Dec 2 for a half-day virtual analytics + data science event!
US & CA customers only

SAVE YOUR SPOT
It's the most wonderful time of the year - Santalytics 2020 is here! This year, Santa's workshop needs the help of the Alteryx Community to help get back on track, so head over to the Group Hub for all the info to get started!

Macro to Delete Null Rows and/or Columns

Highlighted
12 - Quasar

In response to the Idea by @r4upadhye https://community.alteryx.com/t5/Alteryx-Product-Ideas/Data-Cleansing-Tool-gt-Delete-Null-Rows-amp-C...

 

The attached macro will delete rows where all selected fields are null, and/or delete all fields from those selected were all values are null.

 

delete null.png

 

What can be done to make this macro better in any way?

 

Highlighted
Alteryx Certified Partner

Great Solution...

Thanks Joe for bouncing back instantly.....!!!

Highlighted
Alteryx Certified Partner
Alteryx Certified Partner
As a matter of fact yes. I would suggest that you change data types for all fields to BOOL prior to transposing the data. Make the data as light as possible.

Cheers,

Mark
Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and reboot. Order shall return.
Highlighted
12 - Quasar

Thanks @MarqueeCrew and @r4upadhye , macro updated. 🙂

Highlighted
5 - Atom

Thank you Joe. 

But  i am new here. Could i ask two questions?

1)---How can i use this macro that you designed? i replaced the input section by Union, but it seems doesn't work

 

2)---How could i use the every module in Interface like Action\check box and so on. I cannot understand only by the simple description given by click.

 

Thank you again!

 

 

Highlighted
5 - Atom

Sorry for unload wrong document.

Highlighted
5 - Atom

Could you save the Macro in a format that the 10.6 Alteryx can open it as well?

Highlighted
7 - Meteor

This is exactly what I needed. It really should be part of Alteryx.

Highlighted
5 - Atom

I have an Excel file where I had to delete rows if the field in the first column was blank.  Basically it was an ID field and one of two other columns in the row had sub-totals that I needed to eliminate for my data to work in Tableau and not double count the totals.    

 

I was able to use the Filter Tool's Basic Filter.  I selected that first field from the drop down.

 

Then selected "Is empty" (last box is blank).    

 

All of the rows where the first column was blank (empty) were "True" and the rows I wanted to keep were "False."   I then continued the workflow with export into Tableau and it worked perfectly.  

 

Hope this helps someone with a similar situation.  

Labels