Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026 Agenda Now Available: Explore Sessions
cancel
Showing results for 
Search instead for 
Did you mean: 
JonSchwans
Contributor II
Contributor II

SAP Query Returns Negative Value

In data load editor we iterate through a SAP BW query by create a variable for the yearperiod.  We then increment the period by 1.  Each yearperiod value writes a separate qvd, at the end of the load script we combine all the individual yearperiod qvds into a master qvd.  

The issue we have is, the data for the prior year, in this case 2022, comes back as a negative number that does not match any individual number.  For example prior year return -168,000.  If we run the query in BW Query designer for the same year and period the value returned is 106,970,042, which is the expected value.  Oddly when running the exact same query but for current year period data values return as expected.

Looking for any advice to help understand why prior year returns a "random" negative value, yet current year returns the correct value.

Labels (2)
11 Replies
JonSchwans
Contributor II
Contributor II
Author

Thanks again for the input.

I wrote a new SAP BW Query using the basic key figure without any cell restrictions and the correct value was returned for prior year.

I feel the issue is definitely in the communication between SAP BW Query and how QLIK pulls the data.  

At this point my recommendation will be to rewrite and simplify the query, not what the end user wants to hear.

Again I appreciate your time and thoughts....

 

 

JonSchwans
Contributor II
Contributor II
Author

My apology in the delay for responding.  We did a deeper analysis of the data and discovered there was a dimension being used that had three values based on the dimension, 2 of those values offset each other and the third value was the negative amount.

I do appreciate the assistance and I'm happy to report the issue has been resolved.