The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here

Operator to "Where not in " clause

morrgraymorrgray Member Posts: 2 Learner III

Hi, I am looking for a operator that can perform " where not in  ". I have two data sets I want to have rows from first data set which not contain in the seond data set by compare two date columns like :

select * from dataset1

where  dataset1.date not in (select date from dataset2)

How can I do it in Rapidminer? 

Thanks in advance

Best Answers

  • kypexinkypexin RapidMiner Certified Analyst, Member Posts: 291 Unicorn
    Solution Accepted

    Hi @morrgray

     

    It's 'Set Minus' operator which should do the trick, it returns those examples of the ExampleSet whose IDs are not contained within the other ExampleSet. But also note that before applying it you also have to use "Set Role" operator on both datasets and convert those date fields into 'id' type.

  • BalazsBaranyBalazsBarany Administrator, Moderator, Employee-RapidMiner, RapidMiner Certified Analyst, RapidMiner Certified Expert Posts: 955 Unicorn
    Solution Accepted

    Hi,

     

    Vladimir is exactly right, Set Minus is meant for this in a "set operation" way.

     

    If you prefer a more database-like solution or can't set the IDs, do a Left Outer Join with the Join operator and then filter the records where the attributes from the second dataset are not missing.

     

    Regards,

    Balázs

Sign In or Register to comment.