キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Discussions

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

Deleting rows with duplicate values in two columns?

Hello, 

I need to delete multiple rows from my data table that have duplicate values in two columns I specify while preserving the first instance of the row. In the example below, only the third row would be deleted, as both columns are duplicates of row 1. Since the C rows have different results they would not be deleted, even though the entry is duplicated within the column. 

IDResult
AX
BY
AX
CZ
DZ
CX

Conversely, it would work to copy all rows that have a unique combination in those two rows into a different location. 

The most efficient solution, such as a JMP script, would be preferred as my data table is a couple of thousand rows tall, and I would really prefer not to do this by hand. Let me know if I need to clarify anything. Thanks!

1 件の受理された解決策

受理された解決策
jthi
Super User

Re: Deleting rows with duplicate values in two columns?

Select your columns, Select Duplicate Rows, Delete Rows

jthi_0-1724090499781.png

JMP is able to write a script for that action to enhanced log / workflow

dt << Select Duplicate Rows(Match(:ID, :Result)) << Delete Rows;
-Jarmo

元の投稿で解決策を見る

2件の返信2
jthi
Super User

Re: Deleting rows with duplicate values in two columns?

Select your columns, Select Duplicate Rows, Delete Rows

jthi_0-1724090499781.png

JMP is able to write a script for that action to enhanced log / workflow

dt << Select Duplicate Rows(Match(:ID, :Result)) << Delete Rows;
-Jarmo
Mcc99
Level III

Re: Deleting rows with duplicate values in two columns?

Oh, that's super easy thanks!

おすすめの記事