The Why Behind Sum of Squared Errors in a Linear Regression
Simple google search on "stats why regression not absolute difference" would give you good answers. Try it yourself!

I can quickly summarise:


Your regression parameters are solutions to the maximum likelihood optimisation. That involves derivative, but absolute difference doesn't have a derivative at zero. There's no unique solution for least absolute regression.
Least absolute regression is an alternative to the regular sum of squares regression, commonly classified as one of the robust statistical methods.
You'd prefer least absolute regression if you care about outliers, otherwise the regular regression is generally better.


You might want to read about L1 vs L2:


  https://stats.stackexchange.com/questions/45643/why-l1-norm-for-sparse-models