Set Statement

set-statement:
   SET [ schema_name . ] variable_name = new_value_expression
 | SET TIME ZONE { LOCAL | INTERVAL 'hh:mi' HOUR TO MINUTE }
 | SET SCHEMA schema_name
 | SET ROLE role_name
 | SET USER = user_login_name
 | SET SESSION_USER = user_login_name
 | SET SESSION AUTHORIZATION role_name

 | SET [ sys. ] optimizer = optimizer_pipeline_name

Examples

SET CURRENT_TIMEZONE = 3600;
SET TIME ZONE LOCAL;
SET TIME ZONE INTERVAL '+02:00' HOUR TO MINUTE;
SET TIME ZONE INTERVAL '3' HOUR;
SET TIME ZONE INTERVAL '240' MINUTE;
SET TIME ZONE INTERVAL '-3600' SECOND;

SET SCHEMA profiler;

SET ROLE controller;

SET USER = jan;
-- USER is a synonym for CURRENT_USER  

SELECT sys.optimizer;
SELECT * FROM sys.optimizers;
SET sys.optimizer = 'sequential_pipe';

SET schema sys;
SELECT optimizer;
SET optimizer = 'default_pipe';
SELECT optimizer;
SET optimizer = 'ceci_nest_pas_une_pipe';
SELECT optimizer;