AND OR Order in Set User Selection

billrausch

Member
When performing a set of SET USER SELECTIONS, how does JDE know where to put the ().

Does:

fieldA = 1 AND
fieldB = 2 AND
fieldA = 3 OR
fieldB = 4 AND


equate to: (fieldA="1" and fieldB='2') or (fieldA="3" and fieldB='2')

or: fieldA="1" and (fieldB='2' or fieldA="3") and fieldB='2'

Thanks!
 
I haven't tested SET USER SELECTION but the following data selection:

Where fieldA = 1
And fieldB = 2
Or fieldA = 3
And fieldB =4
definitely resolves to
(fieldA=1 and fieldB =2) or (fieldA=3 and fieldB=4).
So I would be quite confident that your first choice is correct.
 
There is a document on the Downloads forum (Subject: ER For Data Selection) that addresses this issue. It may be of use to you.
 
The last post is right... When you're not sure of the effect of data selection remember that logging will always show you the SQL selection generated.
 
Back
Top