Alteryx Designer Desktop Discussions

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

Column Name - Mismatch

suby
Bólide

Hello All,

 

I have a combined output data of which contains two months Data say Data for month end of December and Month end of January.

 

December Data

 

IDPRODUCT ID

 

January Data

 

IDNPRODUCT ID

 

 

The values in PRODUCT ID and NPRODUCT ID are similar.

 

but I'm looking for a solution where i want a formula to say that both columns are same.

 

Thanks

 

9 RESPOSTAS 9
alexnajm
17 - Castor
17 - Castor

I would rename one of them to match the other using a Select tool (ideally rename the one that is not as consistent compared to other months), then you can Union them on together!

binuacs
Arcturus

@suby One way is to transpose the data and take the first row from the PRODUCT ID

binuacs_0-1675703100415.png

 

suby
Bólide

Hi,

 

Thanks for your reply.

 

I agree it can be done using a select tool but i have say 7 months of historical snapshot data so i'm looking for a solution to use a fromula tool to treat it as one column.

 

Thanks

 

suby
Bólide

Hi Binuacs,

 

The data set is huge and i'm looking for a solution where i want to say treat both the columns are same.

binuacs
Arcturus

@suby would you be able to provide some sample data and expected output, it will help to understand your use case better.

alexnajm
17 - Castor
17 - Castor

@suby the parameters have then changed so you'll need to provide some further explanation / something more (i.e. sample data) so we can more directly help

suby
Bólide

Hi,

 

Please see the Sample Data.

 

I have a dataset (.hyper) where the month end data is appended.

 

For the months starting from 30/09/2022 to 31/12/2023 the Column name is PRODUCT ID

30/092022
31/10/2022
30/11/2022
31/12/2022

 

For the months starting from 31/01/2023 to 04/02/2023 the column name is NPRODUCT ID

31/01/2023
04/02/2023

 

when i bring this data in tableau 

 

1) by dragging date column (all Dates) + PRODUCT ID i get nulls for NPRODUCT ID 

2) by dragging date column (all Dates) + NPRODUCT ID i get nulls for PRODUCT ID 

 

the data in both the columns are same so i need a formula to update either PRODUCT ID column or NPRODUCT ID Column to say that if any of these are null then use this.

 

So that i get all the value in one column

alexnajm
17 - Castor
17 - Castor

I would use a Formula tool and create a column called ProductID (notice no space so it's different) and say:

IF [PRODUCT ID]!=Null() THEN [PRODUCT ID]

ELSEIF [NPRODUCT ID]!=Null() THEN [NPRODUCT ID]

ELSE Null() ENDIF

 

basically this says is PRODUCT ID is not null, keep PRODUCT ID... then the same for NPRODUCT ID... and if neither work, make the value null in this new column

suby
Bólide

This works thanks much appreciated...

Rótulos