Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

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

Dynamically skip junk rows/headers from data

Shaaz
9 - Comet

Hi All,

 

How to skip junk rows/headers coming at regular intervals in the data as rows dynamically.

 

Shabaz_1-1652188967556.png

 

In this, I would like remove the rows -,ID,- from this file whereas in the other file instead of -,ID,- it might be -,cocd,-. It has to be dynamic, I should hardcode.

 

Basically remove there junk rows where first column/row has hyphen, columnheader and hyphen.

 

I should get below output.

Shabaz_2-1652189008729.png

 

 

5 REPLIES 5
IraWatt
17 - Castor
17 - Castor

Hey @Shaaz,

You could add a filter like this:

IraWatt_0-1652189370317.png

 

!Contains([ID], "-") AND !Contains([ID], "ID") 

 

It checks the ID column does not contain "-" or "ID". Any questions make sure to ask :)

HTH,

Ira

 

DataNath
17 - Castor

Do your 'junk' records always start with '-,'? If so, the following should do the trick. If not, let me know and I'll take another look!

 

DataNath_0-1652189429674.png

 

binuacs
20 - Arcturus

@Shaaz you can also try with the Data Cleansing tool

binuacs_0-1652189973267.png

 

Shaaz
9 - Comet

Hi All,

 

The above solutions are manual.

 

I’m looking for a dynamic solution where each file will have different column name, it need not be ID always.

 

if a new file has Year as first column, then in data it will hyphen, Year, hyphen.

IraWatt
17 - Castor
17 - Castor

@Shaaz the most dynamic approach I can think of is this:

IraWatt_0-1652193959655.png

Take the field names using the field info tool then join that onto the data, the right join wont contain any headers. The "-" I have to be done manually.

 

Labels