community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Community v19.6

Looks aren't everything... But the latest Community refresh looks darn good!

Learn More

Macro to Delete Null Rows and/or Columns

Quasar
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?

 

Alteryx Partner

Great Solution...

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

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.
Quasar
Quasar

Thanks @MarqueeCrew and @r4upadhye , macro updated. :)

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!

 

 

Sorry for unload wrong document.

Atom

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

Meteor

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

Highlighted
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