[SPARK-2395][SQL] Optimize common LIKE patterns.

I'm not sure what problem you are describing here.  This rule takes a query that is `attr LIKE 'something%' and turns it into the much faster `attr.startsWith('something')`.  Can you describe a case where that is not safe?