Hello ,
I have 2 tables
Data | item | position | Value | position |
Jan-2022 | 10 | A | 50 | R |
Feb-2022 | 20 | A | 50 | R |
mar-2022 | 20 | A | 30 | G |
Apr-2022 | 30 | G | 10 | A |
Data | item | position | Value | position |
Jan-2022 | 20 | A | 10 | A |
Feb-2022 | 30 | G | 20 | A |
mar-2022 | 10 | A | 10 | A |
Apr-2022 | 10 | A | 10 | A |
and merge to one table as below
Data | item | position | Value | position | item | position | Value | position |
Jan-2022 | 10 | A | 50 | R | 20 | A | 10 | A |
Feb-2022 | 20 | A | 50 | R | 30 | G | 20 | A |
mar-2022 | 20 | A | 30 | G | 10 | A | 10 | A |
Apr-2022 | 30 | G | 10 | A | 10 | A | 10 | A |
merge two table and remaining columns are identical
Alteryx doesn't allow columns that have the same name, this cann't be avoided, since the column name needs to be an identifier. I don't think that this is possible in any tool, as it creates a logical error.
If you are just talking about the structure a JOIN on data will do the trick.
Use the Join tool. You can't have two columns with the same name, in the same table.
Chris
@adarsh2608 by default, you can't have names that are the same, as the others have mentioned. However, if you're really particular on this then there is a 'hacky' workaround whereby you can just add spaces to the end of the field name. In the join configuration I've just renamed these. For example the 4 position fields are now 'position', 'position ', 'position ' and 'position ' but appear as normal in the output:
Hi @adarsh2608 ,
As said before, you cannot have two columns with the same name so Alteryx will add a 2 suffix when a second occurrence of a field name that already exists is present. It will increment step by step with 3,4,5... if more columns are added.
For the join, since there are columns with the same name on both tables, it precedes the column names coming from table 2 with a "Right_".
Otherwise for the display of several fields with the same name (imagining that this is what you want), you can precede or suffix your column names with spaces.
Here is a solution attached which gives the expected result.
Let us know if it works.
@adarsh2608 - following the other notes above, some of the following field names could work:
"item" and "item2"
"item" and "item "
"item" and "item_new"
etc.
The reason being is because Alteryx performs data functions, formulas, etc. on column names (i.e. "Item") vs. column location (i.e. column B) as excel does. So each column or field of data needs a unique name so Alteryx knows where your data transformation is taking place.
User | Count |
---|---|
19 | |
14 | |
13 | |
9 | |
8 |