Tag: performance

How to optimize sub folder generation for a FILESTREAM-Enabled sql server Database?

I am familiarizing with FILESTREAM-Enabled sql server Databases. Considering Microsoft’s query to create the database, it becomes clear there obviously needs to be some a folder where to put files after database creation: the filestream1 folder. Such a folder needs to be in an existing data folder CREATE DATABASE Archive ON PRIMARY ( NAME = […]

Fragmentation of one specific index is increasing too often

I have a large table and it has more than 10 indexes. I have a fragmentation problem on one specific index. In the day hours, thousands of rows are being inserted in this table and the fragmentation of just one specific index is increasing very frequently. Other indexes are OK (maybe 0.01% per hour), but […]

SQL Azure query aggregate performance issue

I’m trying to improve our SQL Azure database performamce, trying to change the use of CURSOR while this is (as everybody told me) something to avoid. Our table is about GPS information, rows with a id clustered index and secondary indexes on device, timestamp and geography index on location. I’m trying to compute some statistic […]

Is an “on” criteria quicker than a “where”?

This question already has an answer here: SQL join: where clause vs. on clause 13 answers

MSSQL started working very slow without any reason

Maybe after some updates in windows 10 , MSSQL server started work very slow an not turning on, on windows start, I think maybe some windows defender delay/issue but after turning off windows defender nothing changes. Does anyone have same issue, when mssql starting work very bad with no reason. Running windows 10 64bit, visual […]

SQL Server procedure to populate or create tables from views – performance issues

I have written the below code to populate/create tables (t_) from all of the corresponding views (v_) in my database. I converted a previous script from using a cursor to improve running speed. Is there anything else I can do to make this perform better? Any help is appreciated. Please see my code: SET ANSI_NULLS […]

Linq – Query on 2 Lists Optimization

I am having 2 Lists & I am querying on this 2 List. Both the List are populated with huge data. So the query is taking long time. When I usually face this performance issue, I simply convert SQL queries & run them directly & get the result in a datatable. But this time I […]

Search performance of non-clustered index on binary and integer columns

I store fixed-size binary hashes less than or equal 64 bits in Microsoft SQL Server 2012 database. The size of binary hash may be 48 or 32 bits also. Each hash has an identificator Id. The table structure is like this: Id int NOT NULL PRIMARY KEY, Hash binary(8) NOT NULL I created non-clustered index […]

LINQ multiple joins performance optimization

I need to retrieve a list of orders records, and on the same view I have to show for each order: how many invoices have been issued (InvoiceCount) the total amount covered by the invoices (Invoiced) how much has been paid for the issued invoices (Payed) all on the same grid view. I think it’s […]

SQL Server Performance Issue – Wait Stats?

My laptop is an HP Studio G3 with 16 GB RAM and a Xeon E3-1505 v5 CPU and a 512 GB NVMe Samsung SSD so it’s supposed to be a pretty fast machine. Just recently, I was asked to look at the performance of an application and I duly copied the database and application onto […]

MS SQL Server is a Microsoft SQL Database product, include sql server standard, sql server management studio, sql server express and so on.