Discussion Board for collaboration on QlikView Scripting.
How do you identify which quarter you want if missing?
That's the problem.... I don't know either?
Is there any date field coming in that excel sheet?
This one is easier to do with a Cartesian join.
//100 Names with a few having sales
LOAD * INLINE [
Aaron Roac, 70
Abagail Serran, 300
Abbey Stei, 100
Abbigail Gallego, 1000
//Get the unique list of names
Load Distinct Name
//Use a cartesian product to create 400 rows (100 * 4) bu left joining the Quarters table with no linking field This makes your 400 rows
Left Join (Sales)
//Add in the sales I spread it out 1/4 to each quarter. The ones with no sales get a zero
Sorry, you wanted zeros not nulls. Just add a column to the quarter in line load for nosales with a 0 in it. left join that and add it to sales to get sales with a zero. I will update app
here you go.
Drop all of the junk table to get rid of the synthetic keys.