cancel
Showing results for 
Search instead for 
Did you mean: 

VC application based on BW Queries

Former Member
0 Kudos

Hi,

I am trying to develop an VC application based on queries designed with the Business Explorer Query Designer.

A designed query works fine with the BEX Analyzer, but I have problems using it in VC.

I can add the designed query in VC, but there occur problems using an input form for mandatory variables ( ... Nested Exception: INVALID_VARIABLE_VALUES ...).

I don´t know the correct format for the input fields in VC.

The variables in my query need only Single Value Input.

How can I find out the appropiate format for the requierd input fields?

Thanks in advance.

Slawomir

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Check in BW e.g. in the transaction RSD1 for the InfoObject that your BW query element (field) is based on and press "Maintain data". Then you will see the format.

You can also test every BW query in ther story board by right-clicking and using the "Define/Test query..." option. Tehre you can execute the query and test the format of the values.

For miore BW related issues with VC, see also

https://wiki.sdn.sap.com/wiki/display/VC/Connectivity

Former Member
0 Kudos

Hi Mario,

Thankx for the fast reply.

I know the formats now, but the result is still not the same like in BEx Analyzer.

To be more detailed:

I have a query which shows actual vs planned values for (time)periods for costcenters. I use three variables (planning-version, period and costcenter).

For each row (costcenter) specified periods are shown and within each period (column) planned and actual values (subcolumns) are shown.

When I test the query in VC I obviously use the correct formats for the variables now, because the error doesn´t occur anymore and the output is shown in the output section. But unfortunately only two of the three variable inputs are recognized from VC. The output section shows a wider range of the costcenters than written in the variable filter section.

In BEx Analyzer the query works fine.

What do I have to keep in mind when designing queries for VC ?

Could you give me some advice?

Thanks,

Slawomir

(I already went through the "HowTo Work with Variables"-Paper)

Former Member
0 Kudos

Just to understand better:

1) all three variables are on characteristics?

2) All three really are variables, and not one is just a filter?

3) Can you give examples of the values that you submit?

4) What types of variable are they (single selection...) and which one exactly does not work?

Former Member
0 Kudos

Before answering your questions let me tell you more details about what I´ve done up to now.

When I added the query (described above) in VC model the output port provided the following fields:

Kostenstelle

Kostenstelle_ext_key

Kostenstelle_key

Then I tested the query in VC:

Planning version: 99

Period: 001.2006:003.2006

Costcenter: 0997-0230:0997-0233

After generating the query, more output fields were available:

Kostenstelle

Kostenstelle_ext_key

Kostenstelle_key

2006001_Ist_value

2006001_Plan_value

2006002_Ist_value

2006002_Plan_value

2006003_Ist_value

2006003_Plan_value

I chosed Kostenstelle_ext_key, 2006001_Ist_value and 2006001_Plan_value for output fields in a table and deployed the model.

Concerning your questions:

1) all three variables are on characteristics?

yes

2) All three really are variables, and not one is just a filter?

yes

3) Can you give examples of the values that you submit?

A)

input

planning-version: 99

period: 001.2006:002.2006

costcenter: 0997-0230:0997-0233

output

planning-version: only 99

period: January 2006 (blank columns), March, April, May 2006

costcenters: all costcenters are shown

B)

input

planning-version: 99

period: 011.2006:011.2006

costcenter: 0997-0203:0997-0740

output

planning-version: only 99

period: January 2006 (blank columns), November 2006

costcenters: all costcenters are shown

C)

input

planning-version: 99

period: 011.2006:011.2006

costcenter: 0:0

output

planning-version: only 99

period: January 2006 (blank columns), November 2006

costcenters: all costcenters are shown

4) What types of variable are they (single selection...) and which one exactly does not work?

I changed the types to these:

planning-version: single selection

period: interval selection

costcenter: interval selection

The costcenter variable doesn´t work (see examples above).

Thanks,

Slawomir

0 Kudos

Hi Slawomir,

I suggest you to check again the values you entered for the cost center variable, sometimes it is compound characteristic value. I would run transaction rsrt2 to execute this query, select variable values from value help, and check the web api commands in the results window (VAR_VALUE.... for variable cost center ). that is the value you should use for this variable.

best regards,

Shan

Former Member
0 Kudos

Hi Shan,

after opening the Query Monitor (rsrt2) I chosed BEX Analyzer for Query Display and executed the query.

I used the value help of the input form to select values for each variable.

The input form is filled as follows (e.g):

planning-version: 99

period: 001.2006 and 002.2006 (two input fields for periods due to interval selection)

costcenter: 0997-0230 and 0997-0233 (two input fields for the costcenters due to interval selection)

The result screen (after executing the input form) shows the correct information according to the input.

In my mind the correct value for the costcenter should be e.g. 0997/0997-0230.

The value help also shows this format.

Where exactly should I check the value for the costcenter variable?

What do you mean with VAR_VALUE… ?

Thanks in advance.

Best regards,

Slawomir

0 Kudos

Hi Slawomir,

In rsrt2, on top of the result screen, there is web api command string. look for VAR_VALUE in the command string, the value for this command is the correct value for the variable.

best regards,

Shan