E9.1 Dummy Data Selection Fields

FrankCLT

Well Known Member
Hello Everyone,

I have a weird request from a user, I have a Driver UBE, no BSVW, just calls several BSFN's which is where my data selections take place from PO values I pass in.

User wants Data Selection for Business Unit.

I was just going to add the fields for the data selections to the PO's but user insists on data selections. Is there a way to simulate what happens when you have a BSVW and the ability to do data selections? This would be just to give the appearance of data selections just to capture their desired fields to pass to my BSFN's.

Thank you,
FrankCLT
 
Probably not without an actual bus view on the report. You could just display the process options to the user and allow that to be passed to bus functions for your data selection. Maybe it is a matter of explaining to the user what is happening? You could then add a line at the end of report indicating what process options the user entered for the 'data selection'.
 
Why do you add BSVW of F0006 and pass to your driver section the BUs by data selection?
 
Hello Everyone,

I have a weird request from a user, I have a Driver UBE, no BSVW, just calls several BSFN's which is where my data selections take place from PO values I pass in.

User wants Data Selection for Business Unit.

I was just going to add the fields for the data selections to the PO's but user insists on data selections. Is there a way to simulate what happens when you have a BSVW and the ability to do data selections? This would be just to give the appearance of data selections just to capture their desired fields to pass to my BSFN's.

Thank you,
FrankCLT
Yes but it is kind of ugly. I have done a couple of variations on this but one way:

1. Create a dummy table with the same structure as the real table. If multiple tables you can create one dummy table and join to the other "real" tables. This dummy table needs to exist in the DB and s/b empty.

2. In the Driver UBE make this dummy table/view the first section so user is presented with the out of the box data selection dialog so they can concoct whatever WHERE clause they want.

3. In a BSFNs where you do the actual queries (this assumes those BSFNs are in the driver UBE) use the api ubeSection_GetDataSelection to retrieve the user defined data selection from the driver UBE dummy section/table. You will get back a NEWSELECTSTRUCT array that you will need to loop through and replace the dummy table NID with the real table NID (don't mess with anything else unless you REALLY know what you are doing, the table NID is safe to modify in place).

4. You can then use this NEWSELECTSTRUCT array as data selection in your BSFNs using JDB_SetSelectionX.

5. when done free they NEWSELECTSTRUCT array using ubeSection_FreeDataSelection

One downside is that you will get the "no data selected" output on the driver UBE.

Edit 1:
This also assumes your BSFNs are C BSFNs. May be possible to pass the table handle from a NER to a C BSFN to do the WHERE clause portion but not sure... have not done that.
 
Back
Top