Skip to main content

New answers tagged

0 votes

Automatic index creation - too many

Use this query to find the index using the most reads: --- Index Read/Write stats (all tables in current DB) ordered by Reads (Query 45) (Overall Index Usage - Reads) SELECT SCHEMA_NAME(t.[schema_id])...
Francesco Mantovani's user avatar
3 votes
Accepted

Automatic index creation - too many

In analyzing the indexes, some of them differ only in the 'included' columns while the index columns were same This auto-indexing feature can be good in a situation if you don't have any DBA (...
Aleksey Vitsko's user avatar
0 votes

why CREATE DATABASE FOR ATTACH too slow in parallel?

Running a loop on sys.dm_tran_locks while attaching a database shows, unsurprisingly, that it requires X-locks on rows in various system tables.: sysdbfrag syspru sysbrickfiles sysdbreg Some of ...
Charlieface's user avatar
  • 13.7k
-2 votes

SQL Server Disk throughput slower than diskspd

I think you need to run diskspd tool using 8k, 64k blocks and compare the results. Using 2MB block size for OLTP workload is non-sense. Try: 8 KB block size => resembles the page size that SQL ...
www.askdba.pro's user avatar
0 votes

Manage the amount of data on tables

10M rows/year is less than 1/sec. 100 simple queries per second is not a problem What do the SELECTs look like? If they are getting slower and slower, then they are probably doing "table scans&...
Rick James's user avatar
  • 78.6k
-1 votes

MySQL: How to avoid case sensitivity in SQL queries when migrate from Windows to Linux?

I had a similar problem: I used lower case for all my table and column names, but in my php code I started table/column names with upper case in some places. This gave me no problem on my dev machine ...
Nelson Boro's user avatar
1 vote

Why does moving a postgres table from one tablespace to another take so long

PostgreSQL performs some validation and integrity checks during the move. This includes ensuring that indexes and references remain valid. The process might also involve rebuilding the indexes, which ...
Severalnines's user avatar
2 votes

best set of indices

Use two separated updates instead, to get rid of the OR operator. First update update trades t inner join registries r on t.uni = r.uni and r.nationalid <> '' set t.registry_id = r.rowid The ...
Ergest Basha's user avatar
  • 4,025
3 votes
Accepted

What is the impact on an index when I am widening a key varchar column

200 million existing rows would not be updated and their EmployeeIDs would all still be less than 25 characters" We would just be adding a few thousand new rows that may have EmployeeIDs ...
Aleksey Vitsko's user avatar
0 votes
Accepted

How do I measure the SQL Database responsiveness

-- Identify long-running queries and wait times SELECT qs.sql_handle, qs.statement_start_offset, qs.statement_end_offset, qs.execution_count, qs.total_worker_time, qs....
warashi nguyen's user avatar
-1 votes

How to know when/if I have too many indexes?

I am using this query to find the tables with the highest number of indexes: SELECT Object_Name(object_id) as 'Table', COUNT(*) as NrOfIndexes FROM sys.indexes group by object_id order by NrOfIndexes ...
Balazs Kiss's user avatar
0 votes

Unable to enable Performance Insights on Amazon RDS db.t3.small instance

For Aurora instances, t2 and t3 series, performance insights is not supported. Performance Insights has the following engine class restrictions: db.t2 – Not supported db.t3 – Not supported db.t4g....
Daniel James Canil's user avatar

Top 50 recent answers are included