Microsoft SQL Azure
The process need more CPU, can i change the DTU on the AZURE SQL server from inside the SQL store procedure?
Yes, use command:
ALTER DATABASE [databasename] MODIFY (EDITION = 'Standard', MAXSIZE = 250 GB, SERVICE_OBJECTIVE = 'S4');
You have to test what level is needed for your SQL query’s.
DTU Model is a preconfigured blend of compute, storage, and IO resources at a fixed price. This is the simpler option that is great for paying a fixed amount each month for a preconfigured bundles of resources.
DTU stands for Database Transaction Unit. DTUs give you a way to compare database performance across the service tiers offered by Azure. DTUs roughly measure performance as a combination of CPU, Memory, Reads, and Writes.
100 DTU S3 is less than one CPU core in a on-prem database.
To see current Azure level in a database:
SELECT Edition = DATABASEPROPERTYEX('databasename', 'EDITION'), ServiceObjective = DATABASEPROPERTYEX('databasename', 'ServiceObjective'), MaxSizeInBytes = DATABASEPROPERTYEX('databasename', 'MaxSizeInBytes');