EXECUTE 

Provides a testing mechanism when setting up proxy roles by running CQL commands as another role.

Provides a testing mechanism when setting up proxy roles by running CQL commands as another role during a CQL shell session.

To start, use EXECUTE AS role_name; the commands run with the permissions of the target role. To stop, use EXECUTE AS without a role name.
Note: Requires PROXY.EXECUTE on the target role, see GRANT.

Synopsis 

EXECUTE AS [role_name]

Example 

Begin using the role read_race:
EXECUTE AS read_race;
Executing queries as read_race.
Perform some queries:
SELECT * FROM cycling.race_times;

 race_name                   | race_time | cyclist_name
-----------------------------+-----------+--------------
 17th Santos Tour Down Under |  19:15:18 | Rohan DENNIS
 17th Santos Tour Down Under |  19:15:20 | Richie PORTE
 17th Santos Tour Down Under |  19:15:38 |  Cadel EVANS
 17th Santos Tour Down Under |  19:15:40 | Tom DUMOULIN

(4 rows) 
Stop using the read_race role to execute CQL commands:
EXECUTE AS
Disabling proxy execution