SqlExecutionArea: Support exporting result to CSV file

Add a button which allows the user to save the query results to a CSV
file.

Add some basic preparations for saving the result as a view.