Azure SQL Database pricing is per database server or per user-created database - azure-sql-database

For Azure SQL Database pricing, the pricing is mentioned as $x/hour
Question: Let's say that 'x' is $2/hour. If I create 10 different user databases for my application, will I pay 10 times the hourly cost i.e. $20/hour or will I pay just $2/hour since the cost is for a database server?
I am not sure if I will be charged for each user-created database i.e. each of these 10 databases or just for one database server.

You will be charged for each user-created database i.e. each of these 10 databases depending of their pricing tier.
http://azure.microsoft.com/en-us/pricing/details/sql-database/

A new service plan was announced 04/2015, called SQL Azure Elastic database pool. As of today, it is still in preview mode, but pricing is available here -- make sure you click on Elastic Database button to see the prices.
With Elastic database pool the pricing model is as follows. First, you pay per pool, based on number of performance units you reserve for the pool (DTUs). Then you pay additionally for each database, which is part of the pool. The per-database price is quite small (currently around $1.26/mo), so most of your expenses will be a payments for DTUs, that are shared across all databases of your pool.
UPDATE:
As of May 2016, Azure SQL Database elastic pool is generally available. The pricing details are also updated. As of today, you can get up to 200 databases in Basic Tier for $149/month, which boils down to $0.745 per month per database.

The pricing for Azure SQL Database is per database. This means you would be paying for each of the 10 databases. You can learn more about Azure SQL Database pricing here.

Related

Azure Single Database vs Elastic Pool Databases

I have created an azure SQL single database "w3s_singledb" with no elastic pool and SQL server named "singledb2022dec". After logging into "singledb2022dec.database.windows.net" I executed "create database w3s_seconddb" and it was created.
Next, I created Azure Elastic Pool "elasticpool2022dec" and SQL server named "elasticpool2022dec.database.windows.net". After logging into "elasticpool2022dec.database.windows.net" I executed "create database testdb1" and "create database testdb2". Both were created.
I changed all the databases pricing to basic DTU.
I was trying to understand the basic difference between Single Database and Elastic Pool Databases.?
I know Single Database will be used for "When Application needs a Single Database to work on".
And Elastic Pool will be used for "When Application needs multiple databases to work on and need to share Common Resources like CPU and RAM".
I was trying to understand more elaborately.
The basic idea with an Elastic pool is that you can share resources among databases that need resources at different times. Thereby avoiding paying for idle resources.
Example:
3 databases, set up as 3 single database instance, costs 3X
3 databases, set up as an elastic pool with total resources comparable to 2 single databases, costs 2X
Azure SQL databases are throttled, once you’ve reached the limit of the database resources, additional requests will be timed out.
With an elastic pool, you create a shared resource group for your databases. This can be much more cost efficient, especially when your database infrastructure requires multiple databases or multi-tenancy.
If your database resource usage displays a typical pattern with peaks in performance every now and then, an Elastic Pool might be suited for you.
If your database usage requires large amounts of resources for a longer period of time, it might be a better idea to have a dedicated resource tier for your database.
If you want to change the service tier or compute size of an Elastic Pool, keep in mind that all databases within the pool are affected, briefly. But there will certainly be some kind of downtime during the scaling process. If you need to scale out a dedicated database tier, only that database is affected.

Azure SQL Data Warehouse - Max concurrent queries

I have to decide to use an Azure SQL Data Warehouse or a SQL Data warehouse based on Microsoft SQL Server virtualized on a VM.
The problem what i do not understand is the MAX CONCURRENT QUERIES LIMITATION TO 32. The same for the Azure SQL Database is 6400.
To be honest when i want to use the Azure Data Warehouse in an Enterprise environment the 32 concurrent queries are laughable or i do not understand it.
Lets assume a company with 10.000 Employees worldwide and i set up a Azure Data Warehouse for reporting purpose where lets assume 250 permanently are querying from or additional 250 employees are working with a business app which uses data from the Data Warehouse. How should this work without extreme performance lacks?
This isn't the issue that you might think.
First, the limit is now 128. (https://learn.microsoft.com/en-us/azure/sql-data-warehouse/memory-and-concurrency-limits#gen2-1)
Second, this is well above the concurrency of the next most concurrent single cluster warehouse. I've often wondered what marketing mistake was made by Microsoft that concurrency is seen as a limitation on ASDW, but rarely mentioned for less concurrent competitors.
Third, the best way to serve thousands of concurrent query users (ie, dashboards) is through PowerBI hybrid queries, and (potentially) Azure Analysis Services. This gives extremely high concurrency and interactivity.
Perhaps the best evidence I can give is that I work with Azure SQL Data Warehouse customers on a daily basis. I often get questions like this when a customer is first exposed to ASDW, but I never get questions about concurrency by the time they're in production. In other words, the issue of "concurrency" just isn't important for most customers.

Azure DTUs for a medium size application

I am trying to migrate my ASP (IIS) +SQLServer application from SQL Server Express Edition to Azure SQL database. Currently, we only have one dedicated server with both IIS and SQL express edition on it. The planned setup will be ASP (IIS) on an Azure virtual machine and Azure SQL database.
Per my search on google, it seems SQL server Express Edition has performance issues which are resolved in standard and enterprise edition. The DTU calculator indicates that I should move to 200 DTUs. However, that is based on test run on SQL Express edition setup with IIS on the same dedicated server.
Some more information:
The database size is around 5 GB currently including backup files.
Total users are around 500.
Concurrent usage is limited, say around 30-40 users at a time.
Bulk usage happens for report retrieval during a certain time frame only by a limited number of users.
I am skeptical to move to 300DTUs given the low number of total users. I am initially assuming 100 DTUs is good enough but looking for some advice on someone who has dealt with this before.
Database size and number of users isn't a solid way to estimate DTU usage. A poorly indexed database with a handful of users can consume ridiculous amounts of DTUs. A well-tuned database with lively traffic can consume a comparatively small number of DTUs. At one of my clients, we have a database that handles several million CRUD ops per day over 3,000+ users that rarely breaks 40DTUs.
That being said, don't agonize over your DTU settings. It is REALLY easy to monitor and change. You can scale up or scale down without interrupting service. I'd make a best guess, over-allocate slightly, then move your allocated DTUs up or down based on what you see.
it seems SQL server Express Edition has performance issues
This is not correct.There are certain limitations like 10GB size,one core CPU and some features are disabled ..
I am initially assuming 100 DTUs is good enough but looking for some advice on someone who has dealt with this before.
I would go with the advice of DTU calculator,but if you want to go with 100 DTU's,i recommend going with it ,but consistently evaluate performance..
Below query can provide you DTU metrics in your instance and if any one of the metrics is consistently over 90% over a period of time,i would try to tune that metric and finally upgrade to new tier,if i am not successfull
DTU query
SELECT start_time, end_time,
(SELECT Max(v)
FROM (VALUES (avg_cpu_percent), (avg_physical_data_read_percent), (avg_log_write_percent)) AS value(v)) AS [avg_DTU_percent]
FROM sys.resource_stats
WHERE database_name = '<your db name>'
ORDER BY end_time DESC;
-- Run the following select on the Azure Database you are using
SELECT
max (avg_cpu_percent),max(avg_data_io_percent),
max (avg_log_write_percent)
FROM sys.resource_stats
WHERE database_name = 'Database_Name'

How do I change the online status of an Azure SQL Database to offline

I want to change the status of my Azure SQL Database to offline, but cant see a way to do it from the management portal.
Thanks for reading :-)
You can add a firewall setting to deny all the IP addresses, your won't get double billed and your database is intact. The other option is rename but I wouldn't go with it unless needed.
https://msdn.microsoft.com/en-us/library/dn270017.aspx
For those who are looking to pause the Azure SQL Database to save money, now there is also a vCore-based purchase model for SQL databases in Azure.
After choosing vCore-based billing, you need to choose between:
Provisioned: Compute resources are pre-allocated. Billed per hour based on vCores configured​.
or
Serverless: Compute resources are auto-scaled​. Billed per second based on vCores used​.
If you choose "Provisioned" you can enable "auto-pause" where the database automatically pauses if it is inactive for the time period specified (eg. 1 Hour or more), and automatically resumes when database activity recurs.
Source: https://portal.azure.com
Currently, there is no way to take a database "offline" without deleting the database. A few alternatives are deleting the database and then restoring it at a later day (7, 14, 35 days) depending on the edition of the database (basic, standard, premium) respectively or exporting the database to Azure storage and then restoring at a later date.
For purpose of reducing the expenses you can downscale your database to S0 tier, which allows for same 250Gb as S3 and will cost just 15$ per month.
If you have a premium database with size more than 250Gb, than you can export it to a .bacpac and just delete / re-import. But this actually takes a lot of time and is hard to automate.
Denying all IP-s will not prevent billing AFAIK.

Multi-tenant application on Windows Azure

We want to create multitenant application with shared database table structure.
Currently with standard SQL Server we could achieve that with providing TenantID for each table.
Could we achieve the same on Windows Azure, but without TenantIDs?
Best regards,
Alexey Zakharov
I would think you'd want to do the same thing (use a TenantID column in SQL Azure or in Windows Azure tables).
I concur with the answer smarx gave you, but also consider this: If you have multiple tenants and this drives you above a SQL Azure size limit (say, 1GB or 10GB), you'd need to make a jump to the next-larger database, and this could increase your cost beyond what you want:
1GB: $10 monthly
10GB: $100 monthly
50GB: being released in June, presumably 5x10GB cost
So in the case where you're under the 1GB limit with one tenant, but over 1GB with, say, 2-5 tenants, it would be more cost-effective to set up separate 1GB databases for each tenant, and then manage this sharding in your business tier, based on TenantID.
The question was about another thing. I want to know if Azure SQL provide multi tenant database with shared schema as a feature. – Alexey Zakharov May 21 at 6:00
The short answer is that it doesn't. SQl Azure is essentially (a large subset of) SQL Server.