I have the following table
SourceTbl
FileNum EventCode ChargeDescrip
510-1 DP steal
510-1 DP possession
510-2 DP robbery
510-2 DP firearm
510-2 DP delivery
510-3 DP robbery
I want to spread this data based on chargedescrip
column
DestTbl
FileNum EventCode Charge1, Charge2 Charge3
510-1 DP steal possession
510-2 DP robbery firearm delivery
510-3 DP robbery
How do I do this using a SQL-Query? I found that I might be able to use the PIVOT
clause. But I do go about using it.