Share your ideas for the JMP Scripting Unsession at Discovery Summit by September 17th. We hope to see you there!
Choose Language Hide Translation Bar
Highlighted
JWi
JWi
Level II

Join data into existing table

I'd like to join two data tables by a matching column. However, I do not want JMP to create a new table with the result. The joined columns from the second table should be appended at the first table. I thought the "Update main table ..." option would do this, however it does not work for me (tested JMP 14 and 15). How can I make this work? Here's a minimal example demonstrating the issue:

 

I have to table "Untitled 3" and "Untitled 4", which I want to join by matching values in "Column 1". The join works perfectly if it creates a new table (option "Update main table ..." disabled), the correct result is contained in table "Untitled 17":

Join1.png

However, if I activate the option "Update main table ...", after clicking "Create" still a new table is created, but it is only a copy of table "Untitled 3" and also in table "Untitled 3", the data is unchanged and the data from table "Untitled 4" is not contained:

Join2.png

Here, the join has actually not been performed. I would rather expect that after performing the join in the second screenshot, table "Untitled 3" would contain the additional column "Column 3" with the data as in table "Untitled 17" in the first screenshot.

 

Thanks for any hint.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
pmroz
Super User

Re: Join data into existing table

The Tables > Update command will do exactly what you want.

View solution in original post

2 REPLIES 2
Highlighted

Re: Join data into existing table

I think you misunderstand what the Update Main Table checkbox does. From the JMP Help:

 

Update main table with data from second table

Data in the original table are updated with data in columns that have the same names. The results are displayed in a new data table. Data in the original table are updated with data in columns that have the same names.

Note the following:

JMP does not replace data with missing values.

The output table uses the same columns as the original table. Thus, when you use Update main table with data from second table, Select Columns for joined table is not applicable.

The Update main table with data from second table option is available only when joining by row number or by matching columns.

end of JMP help

 

The join command always creates a new table. If you wish to avoid that, you should consider using a Virtual Join. That is a way to join two tables without creating a third table.

Dan Obermiller
Highlighted
pmroz
Super User

Re: Join data into existing table

The Tables > Update command will do exactly what you want.

View solution in original post

Article Labels

    There are no labels assigned to this post.