[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]ROW
[/TD]
[TD]SESSION
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]4
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]5
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]6
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]7
[/TD]
[TD]Application Started
[/TD]
[/TR]
</tbody>[/TABLE]
This is a sample data taken from an External Excel Sheet.
Our motive is to count the occurrence of "Application Ended" in between "Application Started". and return the desired output as below.
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]S NO.
[/TD]
[TD]Count of Application Ended between application starts
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]2
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]1
[/TD]
[/TR]
</tbody>[/TABLE]
Is it possible to achieve this using Power Query. Please help.
<tbody>[TR]
[TD]ROW
[/TD]
[TD]SESSION
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]4
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]5
[/TD]
[TD]Application Started
[/TD]
[/TR]
[TR]
[TD]6
[/TD]
[TD]Application Ended
[/TD]
[/TR]
[TR]
[TD]7
[/TD]
[TD]Application Started
[/TD]
[/TR]
</tbody>[/TABLE]
This is a sample data taken from an External Excel Sheet.
Our motive is to count the occurrence of "Application Ended" in between "Application Started". and return the desired output as below.
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]S NO.
[/TD]
[TD]Count of Application Ended between application starts
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]2
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]1
[/TD]
[/TR]
</tbody>[/TABLE]
Is it possible to achieve this using Power Query. Please help.