Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
i have a question regarding to the where clause. Here is my example...
Material:
LOAD * INLINE [
M_MaterialNR, M_Preis
100, 50
200, 100
300, 200
];
Material_Temp:
noconcatenate
load
M_MaterialNR as MaterialNR,
M_Preis as Preis
Resident Material where M_MaterialNR = '100'
or M_MaterialNR = '200';
concatenate (Material_Temp) LOAD
M_MaterialNR as MaterialNR,
M_Preis as Preis
Resident Material where M_MaterialNR <> '100'
and M_MaterialNR <> '200';
In the first table Material_Temp is where M_MaterialNR ... OR MaterialNR ..., for becoming only the material 100 and 200.
In the second table is the where clauses with AND for becoming everthing but without 100 and 200. Can anyone explain why?
Thanks...
Perhaps you should ask the person who created that script why he or she used an OR where clause to create the Material_Temp table and an AND where clause in the third load statement. I cannot explain why that person did create that script that way. The result of the load script is to tables with the same content.
Hi,
The two where conditions are opposite:
The first one you select the datas if M_MaterialNR = '100' OR M_MaterialNR = '200' so it can be 100 or 200
The second one you select the datas if M_MaterialNR <> '100' AND M_MaterialNR <> '200' so if it is not 100 neither 200.