Refactored code to support local execution mode - added Spark SQL examples