Data selection

axay72

Active Member
Hi I have query about on the following logic written as internal selection instead of external data selection inside the batch application.
I would like to select a range of record from table F4211 which next status code = '999' and last status code ="800" or next status code ="999" and last status code="900".

I did try to coding two statement inside batch application, but it seem like no responding:-

coding 1:
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<or>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<noner>)

coding 2:
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<or>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<none>)

Before these statement I have execute set Selection Append flag (<Yes>)

I will appreciate your effort giving advise to me.

Thanks and Regards
 
hi, the right way doing your selection is:
Set User Selection(BC Status Code - Next (F4211), <Equal To>, "999", <And>)
Set User Selection(BC Status Code - Next (F4211), <Equal To>, "980", <And>)
Set User Selection(BC Status Code - Next (F4211), <Equal To>, "999", <Or>)
Set User Selection(BC Status Code - Next (F4211), <Equal To>, "900", <And>)

The AND/OR is referred to the previous line. That's all
ciao.
 
Try
Set user selection(BC - Next status code(F4211),<equal to>,"999",<AND>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<AND>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<OR>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<AND>)

Enjoy
OW Hell
 
Hi!
Your Coding 1 is correct. Please try with <and> at the end Instead of <none>
I hohe that you are writing this in Initialize Section Event.
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<or>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<and>)

If it is not working please check your data to make sure that there is any data with these conditions.

Thanks.
Giri.
 
Thank for all of you, the sample you given doesn't work. The system is not coresponding at all.
I will appreciate if you have more suggestion to me.
Thanks
 
I have a similar report and this works fine. The report allows the user to select the Business Unit through external data selection but the report forces the selection of the status of the order line.

In the Initialise Section event rules we have the following code and it works fine. I know this like so many answers given before but thought it may be worth adding my input.

Set User Selection(BC Status Code - Next(F4211), <Equal To>,"999",<And>)
Set User Selection(BC Status Code - Next(F4211), <Equal To>,"980",<And>)
Set User Selection(BC Status Code - Next(F4211), <Equal To>,"999",<Or>)
Set User Selection(BC Status Code - Next(F4211), <Equal To>,"800",<And>)
Set User Append Flag(<Yes>)
 
Set User append flag at the end ?

I don't think that will work, can you comment stavors ?

Christian Audet
 
Hi All

The correct/formal way of coding is:

Set User Append Flag(<Yes>)
Set User Selection(BC Status Code - Next(F4211), <Equal To>,"999",<None>)
Set User Selection(BC Status Code - Last(F4211), <Equal To>,"980",<And>)
Set User Selection(BC Status Code - Next(F4211), <Equal To>,"999",<Or>)
Set User Selection(BC Status Code - Lastt(F4211), <Equal To>,"800",<And>)

However I expect the other solutions to work as well (providing the correct status code is selected (some of the solutions show 'next' instead of 'last'))
Maybe a silly question to Tony, but which event are you putting the code into?

Rgds,
 
Tony,

Sef's question wasn't silly.

You have to place your selection logic into the Initialize Section event, further

A.) Previously you have to set the append flag to Yes or No with the
Set User Append Flag(<Yes/No>)
system function.

B.) You can use the <None> operand only in the first
Set user selection
statement and only when you set the append flag <No>, otherwise use Or/And

I suppose the right code is:
A.) Without appendition:

Set User Append Flag(<No>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<none>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<and>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<or>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<and>)

B.) Witht appendition:

Set User Append Flag(<Yes>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<and>)
Set user selection(BC - Last status code(F4211),<equal to>,"800",<and>)
Set user selection(BC - Next status code(F4211),<equal to>,"999",<or>)
Set user selection(BC - Last status code(F4211),<equal to>,"900",<and>)

Please, let us know you results. Thnx.

Zoltán
 
Ooops,

I edited my previous post:

B.) Without appendition:
>>>correctly>>>
B.) Witho appendition:

excuse me.
 
Back
Top Bottom