[SPARK-3176] Implement 'POWER', 'ABS and 'LAST' for sql

Add support for the mathematical function "POWER" and "ABS" and the analytic function "last" to return a subset of the rows satisfying a query within spark sql. Test-cases included.
Microsoft has some good documentation for how SQL Server handles these things. As an established and very popular product, SQL Server could provide y'all with a good reference implementation for this behavior.

From their [documentation on `POWER()`](http://msdn.microsoft.com/en-us/library/ms174276.aspx):
> Returns the same type as submitted in _float_expression_. For example, if a **decimal**(2,0) is submitted as _float_expression_, the result returned is **decimal**(2,0).

There are a few good examples that follow.

Microsoft also has some good documentation on [how precision, scale, and length are calculated for results of arithmetic operations](http://msdn.microsoft.com/en-us/library/ms190476.aspx).