cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
JMP is taking Discovery online, April 16 and 18. Register today and join us for interactive sessions featuring popular presentation topics, networking, and discussions with the experts.
Choose Language Hide Translation Bar
tom_e_dunn
Level II

update table using JSL without adding missing columns

I'm trying to update the values of a specific column in a data table using values in another data table. The update function seems like the logical choice but it always seems to add extra unmatched columns to the updated table. From the update utility there is an option for this

8498_Capture.PNG

However there isn't any mention of this in either the scripting index

8499_Capture.PNG

or in the help search. I've tried

 

 

dt << update(
     with(dt2),
     match(:name=:name),
     ignore missing,
     add columns from update(none)
);

 

 

but that doesn't seem to work. Does anyone know what the correct option is for this?

1 ACCEPTED SOLUTION

Accepted Solutions
Jeff_Perkinson
Community Manager Community Manager

Re: update table using JSL without adding missing columns

You're almost there!

 

Looking at the Source script that's added to my table after I do an Update with that option I see that the script is:

Data Table( "Trial1.jmp" ) << Update(
  With( Data Table( "Little.jmp" ) ),
  Match Columns( :popcorn = :popcorn, :oil amt = :oil, :batch = :batch ),
  Add Columns from Update table( None )
);

8501_JMPScreenSnapz001.png

 

-Jeff

-Jeff

View solution in original post

3 REPLIES 3
Jeff_Perkinson
Community Manager Community Manager

Re: update table using JSL without adding missing columns

You're almost there!

 

Looking at the Source script that's added to my table after I do an Update with that option I see that the script is:

Data Table( "Trial1.jmp" ) << Update(
  With( Data Table( "Little.jmp" ) ),
  Match Columns( :popcorn = :popcorn, :oil amt = :oil, :batch = :batch ),
  Add Columns from Update table( None )
);

8501_JMPScreenSnapz001.png

 

-Jeff

-Jeff
tom_e_dunn
Level II

Re: update table using JSL without adding missing columns

Thanks Jeff!

xxvvcczz
Level III

Re: update table using JSL without adding missing columns

realized my update table had multiple entries for the same match col.