I think you mean 12p^3-21p^2+28p-49
In which case I can see a factor 3p^2 in the 1st two terms and a factor 7 in the last two terms
So it becomes 3p^2(4p-7)+7(4p-7)
I can now see (4p-7) in both parts so I 'lift' it out and get (4p-7)(3p^2+7)
You can check that these two brackets multiply out to the original question.