on 09-09-2008 6:32 PM
I can get a parameter to display in the report header; however, what I cannot seem to do is to get it to display the descriptive name for that parameter. When I created the parameter and inserted the field, I chose another field for the description or name, which works as desired for the input prompt. What I want is for the report header to display the description or name, not the value.
To be more specific, the parameter value is the accounting period. The key value for the accounting period is a number (e.g., 18). The Name field for the accounting period is 2008-6, which is June 2008. The report header will display the number 18, but I cannot figure out how to get the description, 2008-6. If I simply add that field in the header, it displays the first available record, not the description for that accounting period because there is nothing to connect it to the parameter value.
A trick I've used before when developing reports against SAP BW is to run a hidden subreport in the report header that takes the parameter value and passes it to the subreport as a filter. The subreport returns the data (in this case the accounting period and the corresponding descriptive text). If all you need is one value you simply assign the descriptive text to a shared variable and then reference it back in the header of the main report. If the subreport returns mulitple rows (values), you create a shared array that is then referenced in the main report.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I will try to clarify.
The accounting period key value is a numeric value (e.g., 18) and the Name field is alphanumeric (e.g., 2008-6) in the table OFPR. When the user selects the parameter, it is from a dynamic list that displays the Name field. The numeric value is then used in the Select Expert to include the applicable records.
What I am trying to do is display the Name field for the key value selected for the parameter. I can display the key value, no problem. How do I get the Name field for that key value?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am not sure I understand.
Table: OFPR
Fields: AbsEntry Key Values: 1, 2, . . ., 13, 14, . . .
Name Values: 2007-1, 2007-2, . . ., 2008-1, 2008-2, . . .
{?parameter}=AbsEntry Key value
Let me put it a different way. What I need is a lookup function.
I can see that a subreport would work, but that seems overly complex.
If the user selects ONLY ONE distinct value for the parameter (meaning it runs for ONLY ONE Name Field for the entire report) - Then simply drag the name field into your report header.
If your parameter is marked True for Multiple Values or for a Range and you want to display ALL of the Name Fields the user selected that would be different.
Let us know how your parameter is set up for the Name Field parameter and we can move along with this.
Is this one discreet value being input for the parameter or a range? Is it a string or numeric?
Are you saying that 18 is actually the value the user inputs so that it matches that value in your data field?
Are you also saying that 18 equates to 2008-6 yet there is no field in your data that contains that info?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.