Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

costprice/sale price mapping within date range

productrange:

LOAD * INLINE [

product,stdate,enddate,costprice

a,1-1-2010,28-2-2010,30

a,1-3-2010,20-3-2010,28

b,11-11-2009,18-2-2010,37

b,19-2-2010,31-3-2010,40

];

product_sales:

LOAD * INLINE [

Orderdt,product,salesprice

01-01-2010,a,40

20-03-2010,b,43.23

02-03-2010,a,28.65

];

product costprice saleprice

a        30           40

b        40           43.23

a        28           28.65

2 Replies
Gysbert_Wassenaar

See attached qvw.

Edit: add this at the end to your load script:

join

IntervalMatch(Orderdt,product)

load stdate,enddate, product Resident productrange;

Then create a straight table with product and Orderdt as dimensions and enable the option Suppress When Value is Null for the Orderdt dimension.


talk is cheap, supply exceeds demand
Anonymous
Not applicable
Author

many thanks to you.i am using personal edition.so there is some limition to open the qvw.can you copy paste the code.please dont' mind