Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
kavita25
Partner - Specialist
Partner - Specialist

How to show repeat purchase..

Hi Everyone,

I want to show those customers who was repeated in next month..

stalwar1gwassenaar

Please help me with this issue..

Its really very very urgent....

Regards,

Kavita

22 Replies
kavita25
Partner - Specialist
Partner - Specialist
Author

Thank You for ur precious time and response..

swuehl
MVP
MVP

Here is another ( IMHO more flexible)  approach:

Result:

LOAD

  Key,

    If([DMS Outlet Code] = Previous( [DMS Outlet Code]),Previous(MonthCounter) - MonthCounter ) as ReturningAfter

RESIDENT TMP

ORDER BY

    [DMS Outlet Code],

    MonthCounter desc  

  ;

kavita25
Partner - Specialist
Partner - Specialist
Author

Okay... i'll try this one also..

Can u please tell me..

How will I check the particular month has no sale but previous month has sale..

For e.g: Dec has no sale but Nov has sale..

And

Previous 2 month has sale but the previous 1 month and the particular month has no sale.

For e.g Oct has sale but (Dec and Nov) has no sale.

The only above logic is left to do..

Kindly guide me..

And thank you soo much...Really appreciate ur help..

Regards,

Kavita

kavita25
Partner - Specialist
Partner - Specialist
Author

The first one is correct...

Thanks Again..

swuehl
MVP
MVP

The first question can be answered just like the question that already has been answered before, you just need to change the sort order and add another field.

The second question could be answered using my second approach and filtering ReturningAfter >2 (or including maybe NULL).

kavita25
Partner - Specialist
Partner - Specialist
Author

For the first logic..

If(Previous(MonthCounter) = MonthCounter - 1 and  [DMS Outlet Code] = Previous( [DMS Outlet Code]),1,0) as ReturningIn1

RESIDENT TMP

ORDER BY

    [DMS Outlet Code],

    MonthCounter asc

  ;

Is it correct??

swuehl
MVP
MVP

Yes, something like this. Just give it a try and test thoroughly.

kavita25
Partner - Specialist
Partner - Specialist
Author

swuehl

stalwar1

gwassenaar

Please help me with the issue...

How will I check the Max month has no sale but previous month has sale..

For e.g: In my data Max month is Dec has no sale but Nov has sale..

And

Previous to previous month has sale but  Max month and previous month has no sale.

For e.g Oct has sale but (Dec and Nov) has no sale.

kavita25
Partner - Specialist
Partner - Specialist
Author

Hi,

please help me to do this logic

sunny_talwar

I am very late to this discussion and will have to check each and every response before I can answer anything. Also, you are getting help from two of the best here. I am going to let them continue helping out here