Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Add Coulumn

$
0
0

I have a column like Below:

Code    Description  Season  A$   B$  C$  D $

10         AP              FA13     3    4     5    6

20         BC              SP15     4   5     6     7

10         AP              SU12     3    4    5      5

10         AP              FA13      10   2    1     2

20         BC              SP15      2     7    1     3

Now I need a  add only column A with same code, same seson (Description is always same), had to add column B (same way) and c and D.I want all these value to land at same column. Then add another column saying if it is A$,B$,C$ or D$. This is what I am Looking....

Code    Description  Season  Measure    Measure Code 

10        AP               FA13    3                A$

10        AP               FA13    4                B$

10        AP               FA13    5                C$

10        AP               FA13    6                D$

20        BC              SP15     6                A$ (Its adding A$ as it has Code,Description and Season common)

20       BC               SP15     12              B$

and so on.

Can someone please help me to figure this out?


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>