How to split dynamic column values to dynamic multiple column values
<p>I have a problem splitting dynamic column values to dynamic  multiple column.</p>

<p>i have table like this:</p>

<pre><code>media campaign number  ---  Dynamic varchar
-----------------------------------------------------
1    --- d1:11d2:5d3:11d4:0
2    --- d1:2d2:2d3:3d4:2d5:0
3    --- d1:0d2:0d3:1d4:4d5:0d6:2d7:1
</code></pre>

<p>I want to separate the cell  into dynamic number of columns, according to times the "dNumber" appear.</p>

<p>The result will be :</p>

<pre><code>media campaign number -- d1 - d2 - d3 - d4 - d5 - d6 - d7
1 - 11 - 5 - 11 - 0
2 - 2 - 2 - 3 - 2 - 0 
3 - 0 - 0 - 1 - 4 - 0 - 2 - 1 
</code></pre>

<p>Any idea how to solve it?</p>