In order to get the ninth chord, you have to add the 9th note of the major scale to the seventh chord. But how do you get the ninth note of a scale? Let’s look at the C major scale. The C note is the 1st note, then D is the 2nd note and so on. When you reach B, that’s the 7th note and then back to C. Now the C after the B note is considered the 8th note, and then the D note is the 9th note

C D E F G A B C D E … 1 2 3 4 5 6 7 8 9 10

Add D note to the C7 chord and this gives you the C9 chord which is C E G Bb D. Easy isn't it?