3 Replies Latest reply: Nov 21, 2010 7:09 PM by Matthew Green RSS

    Equivalent of sql's IN statement for a Resident load

    Matthew Green

      I have a sql table which has 50 columns labelled DX1, DX2.. etc as well as other columns.

      I'm loading this table in, and now want to create a new table, which is a filtered version of the SQL Load.

      The filter is that one of the 50 DX columns must be one of 6 possible values ('J45','J450','J451','J458','J459','J46')


      In SQL i would do this using the IN statement as follows


      WHERE (DX1 IN ('J45','J450','J451','J458','J459','J46')

      OR DX2 IN ('J45','J450','J451','J458','J459','J46')

      OR DX3 IN ('J45','J450','J451','J458','J459','J46')

      OR DX4 IN ('J45','J450','J451','J458','J459','J46')



      This doesn't work for a Resident load though. I've also tried using MATCH, but this didn't seem to work.


      Any ideas?