Extending the SQL to include the update statement