キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to move from signal modeling to system modeling at the first JMP Aerospace Analytics webinar. Register. June 18, 1 p.m. US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
言語を選択 翻訳バーを非表示
ivan_j_moore
Level III

Joining / Concatenate table but just include new data

Hi all,

I have scheduled a JMP script to give me a daily data table each day.

What is the best way to Concatenate these tables, but I only want to add new data and not have multiples.

Example Table 1 (Day 1) and then table 7 (Day 7), how do you concatente these tables to have Table 1 and all new data in Table7 included, but not multiples.

Note, Column names will be the same in each table.

5件の返信5
txnelson
Super User

Re: Joining / Concatenate table but just include new data

Assuming that you have a column or multiple columns that uniquely identify each row, then all you have to do, is to use Join, rather than Concatenate, and to match on the identification column(s). Also make sure that you specify to Merge Same Name Columns and to include non matching records from the "With" table.   That will provide you with what you want.

Jim
ivan_j_moore
Level III

Re: Joining / Concatenate table but just include new data

Hi Jim,

Thanks for the help, again this worked a treat, Only thing I have to include "Non matches" in both tables if I want to make the table include al that data I am looking for, however this makes sense too.

Thnaks.

txnelson
Super User

Re: Joining / Concatenate table but just include new data

ah...you are correct about the Include the non matches from the base table....my error

Jim
ivan_j_moore
Level III

Re: Joining / Concatenate table but just include new data

Hi Jim, the key point for me here was "Merge Same Name Columns" which I hadn't used before.

Thanks for your help much appreciated.

ms
Super User (Alumni) ms
Super User (Alumni)

Re: Joining / Concatenate table but just include new data

Yes, Join is a powerful tool.

In case you already have created a table a lot of multiples there are several ways to identify and delete duplicate.

Below is my (current) favorite jsl snippet for deleting multiple instances. It now compares all columns, but can be tweaked to just consider a limited set of columns.

// Keep only first instance of multiples

dt = Current Data Table(); // Table with potential multiples

instance = Parse("ColMin(Row(), :Name(\!"" || Concat Items(dt << get column names(string), "\!"), :Name(\!"") || "\!"))");

dt << delete rows(dt<<get rows where(instance < Row()));


おすすめの記事