I have a table with different contract numbers and payments on each contract number for each month for example:
C# | amount | month
1234 | $50 | JAN
1234 | $75 | FEB
5676 | $100 | JAN
5675 | $150 | FEB
6754 | $25 | JAN
6754 | $50 | FEB
6787 | $30 | JAN
6787 | $0 | FEB
I want to be able to do a comparison of each contract number in a table comparing what was pain in JAN vs. what was paid in FEB so that result would be like
OK, I understood that part in the output. There are two different C# values in the input: 5676 and 5675. I am guessing that this is a typo, and not intended to be part of the problem?
mrroy69
ASKER
I'm sorry that was a typo on my part they both should be 5676
Sigh. So the months are not stored in the way you showed us in the question? For future reference, please show us the actual information. It will save everyone a lot of time!
mrroy69
ASKER
Thank you!
Sharath S
Agree with Ray. My query works fine for the information provided initially. Expected a split here but not worried about points.
Actually Sharath I tried your solution however, it did not give the expected results. Though it returned all of the rows most of the amounts showed up as 0.00. I appreciate your help
Sharath S
Well. In that case, it should have communicated that it's not working.
Open in new window