MLOAD APPLY WHERE condition which is not an equality

Tools
Enthusiast

MLOAD APPLY WHERE condition which is not an equality

I have a very simple working MLOAD and have a new requirement to block data from being INSERTED.  I see many examples where the WHERE of an APPLY statement is specified as equality (=) and am sure I've done that in the past successfully, but my new requirement is to skip based on 'not equal to'.

Layout of file:

.LAYOUT INFILE_LAYOUT;

.FIELD INP_STR * INTEGER ;

.FIELD INP_ITM * INTEGER ;

Current IMPORT statement

.IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

;

I have attempted all these variations, and all cause all records to fail the "Apply conditions satisfied" 


0017 .IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

WHERE INP_STR <> 10108

;

0017 .IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

WHERE INP_STR <> '10108'

;

0017 .IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

WHERE INP_STR ¬= 10108

;

0017 .IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

WHERE INP_STR NOT IN (10108)

;



0017 .IMPORT INFILE INSERTS

LAYOUT INFILE_LAYOUT

APPLY INSERT

WHERE INP_STR < 10000

;





All the attempted filters skip all the records.  (I have not yet put data in the file for the entity to be filtered.)

     .                                       IMPORT  1     Total thus far

. ========= ==============

Candidate records considered:........ 4659129....... 4659129

Apply conditions satisfied:.......... 0....... 0

Candidate records not applied:....... 4659129....... 4659129

Candidate records rejected:.......... 0....... 0

I've confirmed the data is applicable to be satisfied by all the conditions I have applied.  Example data follows:

 File-AID - Browse - T01.SEH.TD3

COMMAND ===>

store item FILLER

4/BI 4/BI 1/AN

(1-4) (5-8) (9-9)

1---------- 2---------- 3-------

********************************

1802 105472

866 551254528

482 551255040

1080 551255808

2136 105472
MultiLoad Utility    Release MLOD.15.10.00.002

Platform MVS

Tags (3)
1 REPLY
Enthusiast

Re: MLOAD APPLY WHERE condition which is not an equality

It turns out that there was a second IMPORT statement involved here.  I had to add a "superfluous" condition on that IMPORT to get the behavior I expected to see with the IMPORT command used above.

Second import was:

.IMPORT INFILE DELETES

LAYOUT INFILE_LAYOUT

APPLY DELETE;

 

and was changed to 

 

.IMPORT INFILE DELETES

LAYOUT INFILE_LAYOUT

APPLY DELETE WHERE 1=1

;

And then the first import worked as expected (when a WHERE clause was added).