Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Azure SQL Database is a relational database-as-a-service from Microsoft. This tag is for questions about Azure SQL Database, NOT SQL Server hosted in an Azure VM (use azure-vm).

0
votes
0answers
5 views

Login failed for admin user error in Azure SQL Database using Invoke-Sqlcmd

I am using Powershell module 'sqlps' to create a copy of one of the databases in my Azure SQL Server using invoke-sqlcmd. The complete command line- Invoke-Sqlcmd -ServerInstance "myServer.database....
2
votes
1answer
64 views

Can an application connect to databases from on-premise SQL Server Instance and Azure SQL together?

Can a single application connect to two different databases each of which is in different Instances. One instance has on-premise deployment, the other one is Azure SQL(not SQL in Azure VM). So ...
1
vote
2answers
35 views

SQL Maintenance Tasks on Azure [Ola Hallengren Scripts]

I am trying to implement the SQL maintenance scripts from Ola on my Azure elastic pool databases. I did the steps as provided in this link. I could create the job, but I always get this error after ...
1
vote
1answer
24 views

SQL Server - How to improve/optimize remote scan on a linked server

I'm trying to figure it out how to optimize/improve the following thing, on a VM hosted in MS Azure and a database, also hosted in MS Azure. Besides the instance hosted in MS Azure, there is another ...
5
votes
0answers
155 views

Cardinality estimation on tables with large cardinality variance between keys

Context I have stumbled on an issue in SQL Azure where the Sort-operator is spilling over into TempDB due to poor row estimates. We are querying a master table that is joined with a number of detail ...
1
vote
1answer
31 views

Copy real time data from Azure SQL into Azure Data Warehouse

I would like to copy our data from Azure SQL (OLTP) into Azure Datawarehouse. I want the path to be close to real time. The Microsoft system looks it takes two steps copying data from SQL Server into ...
1
vote
1answer
82 views

Migrate on-premise SQL Server databases to Azure SQL Database

We're in the process of a server migration from an on-premise server (Win2008R2) to Azure PaaS. To move the databases, we used the Microsoft Data Migration Assistant (DMA) tool, which worked great ...
2
votes
1answer
49 views

Difference between Clustered Columnstore Index Table in Azure SQL and Table in Azure Data Warehouse

What is the essential difference between a Clustered Columnstore Index table in Regular Azure SQL, and a table in Azure Data Warehouse? They both have columnar storage, no foreign keys, no primary ...
1
vote
0answers
22 views

Spin up an extra sql azure instance to reorganize/rebuild indexes with no downtime

We have a pretty large sql azure database, over 300GB. Many tables have been altered over time and we would like to create fresh indexes, including clustered ones. Of course we would like to minimize ...
1
vote
1answer
47 views

Azure SQL DB vs Azure managed instance [closed]

We are in the early stages of planning to move some of our on-premise database to cloud and wanted to go the PaaS way. I understand that managed instance is in preview. From what I have read, ...
2
votes
2answers
40 views

Permission error when using sys.dm_exec_input_buffer with @@SPID

When I run this blob of SQL on SQL Server 2016 or an Azure SQL DB: --hello world SELECT event_info FROM sys.dm_exec_requests req CROSS APPLY sys.dm_exec_input_buffer(req.session_id, req....
5
votes
1answer
278 views

Read Committed Snapshot, stale data reads?

I'm running SQL Azure and I have a following case. I have two transactions W (writer) and R (reader). Both are running with RCSI (.net application with TransactionScopes using LTM). The R transaction ...
1
vote
1answer
23 views

cause of / how to fix a table with excessive reserved pages

I have several tables with clustered indexes in azure PaaS sql server which have blown out to be much bigger than their data, with reserved page count several times bigger than the actual amount of ...
1
vote
1answer
24 views

Azure SQL Server External Data Sources

Let me preface this what what I'd like to accomplish and see if this is inline with the expectation of using Azure SQL DB. Currently I use a couple Virtual Machines in Azure that use a linked server ...
0
votes
1answer
32 views

Advanced threat detection vs IP restriction

If we configured IP restriction to allow only internal network, then why we need threat detection? IP restriction already blocks connections from other resources. Moreover, advanced threat detection ...
1
vote
1answer
212 views

GRANT select on function FN_DUMP_DBLOG in SQL Server without GRANTing sysadmin

I'm trying to GRANT permission for an SQL login to access the functions fn_db_log and fn_dump_dblog but GRANTing SELECT on the function still fails with error: Msg 9010, Level 14, State 1, Line 3 ...
1
vote
1answer
83 views

Full Outer Joins Slowing Down Query

I am relatively new to SQL, so I apologize if I ask some basic questions. Our database is setup on Azure, we have automatic indexes turned on. The query I have takes about 6 seconds and gets 2217 ...
0
votes
0answers
36 views

Users are missing in Database restored from .bacpac file

I am creating a new database from a reference .bacpac db file but the issue is that in the new Database, users are corrupted and I cannot login through any of the database users that were there ...
1
vote
0answers
27 views

Azure's New Tiers (2018) - Standard vs Premium

We've done what we can to index things intelligently, but we're beginning to scale up our database usage and have decided scale up (?) from Azure's S4 tier to P1. It looks like P1 has fewer DTUs and ...
0
votes
1answer
50 views

REORGANIZE INDEX blocks other queries

(SQL Server 12.0.2000.8 running in Azure) It has been my understanding that REORGANIZEing an index should not interfere with other operations (that is, it should not block queries on the table ...
0
votes
2answers
53 views

Error 0x80131904 failed to load assembly id 65536 / HRESULT: 0x8013150A for microsoft.sqlserver.integrationservices.server

I am running SSIS Packages through an Agent job and getting error 0x80131904: Message: Executed as user: NT Service\SQLSERVERAGENT. Microsoft (R) SQL Server Execute Package Utility Version ...
0
votes
1answer
15 views

A Common Username for Both Database hosted in Azure

I have 2 azure databases created in one SQL Server. I.e. Database 1 = db1 in xsqldb01.database.windows.net Database 2 = db2 in xsqldb01.database.windows.net I would like to create a username or user ...
0
votes
0answers
32 views

Way to link to Oracle DB from SQL Azure DB

We currently get data from our Oracle DB by creating it as a linked server from our on-premise SQL server database. We are considering moving to the Azure SQL and would still require data from on -...
4
votes
2answers
207 views

Azure SQL Server Database Error: 18456, Severity: 14, State: 1

Why can't I login to my SQL Server database on Azure, and how do I correct this? No one in our company has changed the password of our Azure SQL Server database administrator user, yet I'm getting the ...
5
votes
2answers
85 views

How secure is an Azure database within Microsoft?

I am considering moving most of my Databases to Azure SQL server Database, but I am concerned that Microsoft will be able to snoop and look at the data inside the database, which is absolutely not ...
0
votes
1answer
88 views

How to correct SQL Server Import and Export Wizard error that says my data conversion length must be between 0 and 4000?

The message I get from the 2017 SQL Server Import and Export Wizard which I need help with is, "Error 0xc0204016: SSIS.Pipeline: The 'Data Conversion 0 - 0.Outputs[Data Conversion Output].Columns[...
1
vote
1answer
36 views

Is it good practice to have relationship between the tenant table and all other tables in a multi tenant application?

I am developing a multi tenant SaaS that uses Azure SQL for data storage. I make use of sp_set_session_context to make sure that any query only touches records relevant to the current tenant. I ...
0
votes
1answer
52 views

What would cause a transactional replication subscription to restart repeatedly with no errors?

I have set up a transactional replication publication/subscription to test a migration from an on-premise SQL 2016 Enterprise Edition installation to Azure SQL DB and I'm finding that when the ...
2
votes
1answer
45 views

Migrating 300GB database to Azure SQL Server

We are having a devil of a time trying to migrate our current on-premises SQL Server to an Azure SQL Database. It is large but not that large (about 300 GB). We've tried the "Publish to Azure" option ...
0
votes
1answer
18 views

Is there a way to restrict automatic statistics updates to a certain timeframe?

I have an Azure SQL Database that runs on average at < 10% DTU capacity. It seems that at random times during the day large statistics update queries will execute on the database, causing DTU (...
5
votes
2answers
92 views

Experiencing CLR error on SQL Azure DB

Out of nowhere we started seeing this error and it seems to occur fairly frequently when making calls to the database or any other database in our Elastic Pool. The DTUs aren't being maxed out and the ...
4
votes
1answer
412 views

How can I clear buffer for a SQL Server DB Hosted On Azure?

I am trying to fine tune my queries and Stored Procedures. The Issue that I am facing is that there is no way to clear the Database buffers in Azure. Which means that I cannot use DBCC ...
0
votes
1answer
45 views

How to copy data from Azure SQL DB into Azure SQL DW

I need to copy some data from an azure SQl DB instance into my azure data warehouse. The most obvious way to do this is to use Elastic Query, similar to the below: CREATE EXTERNAL DATA SOURCE SqlDb ...
0
votes
0answers
30 views

Unable to configure Alerts on Metrics for Azure SQL DB

I am trying to configure Alerts(not classic alerts) on Metrics for an Azure SQL DB. I have navigated to the "Create rule" blade under Monitor The problem is when I select a SQL database target the ...
1
vote
1answer
28 views

Is it possible to set up Azure as a publisher for Pull Replication to an on-premise database?

I am trying to set up Pull Replication from an Azure database to an on-premise database. I have set up the on-premise database as the distributor but when I try to establish a subscription to the ...
4
votes
1answer
230 views

Cannot create SP in Azure SQL Database

I am trying to create a stored procedure on my Azure SQL Database, which has joins to other database table in Azure SQL Database. I am getting the following error while creating the Stored Procedure: ...
2
votes
1answer
98 views

Out of Memory Exception When Creating BACPAC File

We're having a frustrating time migrating our on-premises SQL application to Azure. The database is large but not crazy, about 265 GB. SQL Server Management Studio > "Deploy Database to Windows Azure ...
-1
votes
1answer
127 views

Oracle Linked Server in Azure SQL Database Managed Instance

I am migrating my On Premise SQL Server to Azure SQL Database Managed Instance. But I have linked server to Oracle database in my SQL Server. Can we create linked server to an On Premise Oracle ...
0
votes
0answers
33 views

BigData IoT table without foreign key

We thinking about switching our database structure to a more modern schema. We hope to reduce server performance peaks and gain more performance. This for I read some concepts about general so called ...
4
votes
3answers
286 views

Using CROSS APPLY OPENJSON causes Azure to hang

I have a table with around 8 million rows with a schema of: CREATE TABLE [dbo].[Documents]( [Id] [uniqueidentifier] NOT NULL, [RemoteId] [int] NOT NULL, [Json] [nvarchar](max) NULL, [...
24
votes
5answers
3k views

Changing the use of GETDATE() in the entire database

I need to migrate an on-premises SQL Server 2017 database to an Azure SQL database, and I'm facing some challenges since there's quite a bit of limitations to go through. In particular, since an ...
2
votes
2answers
144 views

How to Limit DTU Percentage Consumption for a Given Session in Azure SQL Database?

We have an Azure SQL Database tier S4 (200 DTU), and there is one big table inside When I run a "alter index rebuild..." statement, it takes about 18 mins to complete This particular nonclustered ...
1
vote
1answer
77 views

Does Azure SQL Data Sync support MySQL or SQLExpress?

I did see that it supports SQL Server (2005 and later) but does it support syncing between a SQLExpress server or MySQL server and an Azure Server? I'm trying to use it with a SQLExpress server but ...
0
votes
1answer
31 views

Best High Availability Solution for SQL Server 2014

Please we are about to implement High availability for for SQL server 2014 on our new infrastructure but i need to know which is best between SQL Failover Clustering and Always On High Availability ...
0
votes
1answer
192 views

MySQL Workbench Unable to Connect to Azure Databases for MySQL

When trying to connect to a MySQL database in Azure I get the following error: ERROR 2026: SSL connection error: socket layer receive error At first I thought it was a firewall/security issue but ...
1
vote
2answers
65 views

Stored Procedure return unwanted cursor result

Context I have created a stored procedure that simulates a merge command for an OLTP in-memory table. It used the simulated merge for upsert moving massive data form a normal table to an OLTP one. ...
2
votes
0answers
40 views

Is there a way to programmatically get the version of a .bacpac file without unzipping and inspecting the xml?

The situation is that we get a copy of the latest production bacpac, then restore it locally when setting up our dev environment. During the setup, we do an explicit check for the DacFX dll but target ...
1
vote
2answers
91 views

How to force/require TLS connections on SQL Azure

You can make a secure connection to a SQl Azure instance following these instructions from microsoft. However, this only works when the user specifies it in the connection string. How do I set SQL ...
0
votes
1answer
158 views

Statistics update on Azure SQL DB

New to Azure SQL DB. I was wondering what is the best practices for scheduling jobs like update statistics in Azure SQL DB. Googling got a couple of blogs that uses Azure automation. https://blogs....
6
votes
3answers
361 views

Why does this query take so long to execute?

I'm currently using Microsoft SQL Azure (RTM) - 12.0.2000.8 as the database. The database currently has 10 DTUs. The idea here is that I want to make the query based on the view. This view contains ...