Dynamic Selection for a Query

Question: Hi All,

Let me explain the requirement for a Query.

There is a Z-Table in BW which contains a list of Material , fed every day from a non-R/3 source system.
There is a BEx query which is to be run only for those material which are listed in the Z-Table.
Further, the result for this query is to be extracted through RSCRM_BAPI.
This is a daily activity and hence need to be automated.

Need some suggestions from the forum in order to arrive at the best possible solution.

Thanks and Regards,
Mit

Answer:
at least 3 solutions :
First, create a customer exit variable on product, which will be filled in in ABAP by the content of the table
Second, add a flag on your product master data, and update this flag every day according content of the table
Third, put these data into one infoobject on which you create a query, and create a Value Set in reporting agent, refreshing it every day, and use this value set to fill in a variable.

I suggest personnaly the 3rd solution if you're at least in 3.0.
_________________
When my car stops, I first look at the gasoline's level before dismounting the engine.


Tuly Idiot's fan club active member.

Answer:
Hi Fred,

Thanks for the valuable inputs.
Yes, I am in 3.0B and would like to more about the third option you have suggested.( as I have never worked on this part.)

put these data into one infoobject on which you create a query, and create a Value Set in reporting agent, refreshing it every day, and use this value set to fill in a variable.

Can you please explain this a bit further or probably a document(or link) can be of great help.

Thanks again,

Mit.

Answer:
First create an infoobject in which you'll store the list of material.
second, create a query on it which will retrieve the values
Third, go in RSA1, Reporting Agent, Value Set..create the value set, as if you create a reporting package (quite the same screens)... schedule it, and so on ... at your period wish.
Fourth, go in query designer, create a variable choosing User entry/precalculated value set. That's All.
I don't have any specific doc on this, but searching on SAP could be a good idea.
_________________
When my car stops, I first look at the gasoline's level before dismounting the engine.


Tuly Idiot's fan club active member.

Answer:
Thanks !

Answer:
Or without valueset:
(Make your z-table a dataprovider).
Create a query with as output your required material in the rows. Take care: it should not be ready for input.
This will be your so called pre-query.
Now in your bex query create a variable for material, processed by "Replacement path". Replace with query result of your pre-query.
Copyright ?2007 - 2008 www.jt77.com