Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Attached an excel sheet, the problem is explained in the sheet itself with the output.
if(Product=previous(Product) and Category<>Previous(Category) and ColumnNoOdd<>ColumnFrom
then remove the Category for that Product from the sheet
Regards
See attached qvw
Hi,
The qvw attached does what is required but actually i'm loading data by Resident Load and for when i use
if(Product=previous(Product) and Category<>Previous(Category) and ColumnNoOdd<>ColumnFrom,1,0) as Flag
i get the result below where incorrectly i get one additional row (having 1), this 1 shud actually be in the above row instead of a zero(0).
why does it behave that way ?
Since the excel sheet is already sorted by Product,Date,ColumnFrom,ColumnOdd so it was required for you to use order by but i had to use Order by Product,Date,ColumnFrom,ColumnOdd.
Also,why did you use first 328, can't we remove that ?
Product | Category | Date | ColumnFrom | ColumnNoOdd | Flag |
2267 | SY, Cqvbdwmmeht, Pmdqop Hwerlv (Uyirsqw) | 08/10/2012 | 1 | 1 | 0 |
2267 | RJ, Yubiefpa, Tssgduk | 05/04/2013 | 7 | 13 | 0 |
2267 | RJ, Yubiefpa, Tssgduk | 05/04/2013 | 7 | 13 | 1 |
2267 | RJ, Yubiefpa, Tssgduk | 23/04/2013 | 7 | 16 | 0 |
2267 | DA, Xsiacmwu, Tymfte VI (Rny Yrzk) | 23/04/2013 | 16 | 16 | 0 |
2267 | DA, Xsiacmwu, Tymfte VI (Rny Yrzk) | 31/05/2013 | 16 | 20 | 0 |
2267 | DA, Xsiacmwu, Tymfte VI (Rny Yrzk) | 27/06/2013 | 16 | 24 | 0 |
2267 | TK, Fshjmctbj, Wnannr TZ (Vnsioacph) | 27/06/2013 | 24 | 24 | 0 |
2267 | TK, Fshjmctbj, Wnannr TZ (Vnsioacph) | 15/06/2014 | 24 | 56 | 0 |
Regards
I don't see any difference using a resident load to order the records.
yes, u're right resident load shudn't make a difference at all, thats why i exported the data and attcahed it in excel
But why do i get two lines for 2267 as pasted in the above post when i a add the column flag ? Any ideas ?
Regards
thanks...it finally worked on resident too....