Building stored procedures
Building a stored procedure is very straightforward. Stored procedures, triggers, and user-defined functions can be created by using the Script Explorer on the Azure portal:
To create a new stored procedure, click on the Create Stored Procedure button.
This stored procedure creates a separate document inside the collection containing the username, action, and date. This stored procedure can be used, for example, in the trigger we create later in this chapter to keep track of all the actions that are performed inside the system. At the time of writing, executing stored procedures from the Query Explorer in the Azure portal was not yet enabled.
Note
At the time of writing, executing stored procedures from the Query Explorer in the Azure portal is not possible.
Try executing this stored procedure by using the code snippets that were provided in Chapter 3, Basic Querying.