Here's a few of the new posts today on the forums. To see more, visit the forums.
|
SQL Server 2017 - Administration |
What other useful DBA reports do you suggest? - What other useful DBA reports do you suggest? Maybe something we would run every month or so to check that our environment is configured/running optimally. We have these so far: see screenshot. I also already have (adding soon) certain reports on block leaders and Waits report based on sp_whoisactive, report on 'Worst of the Worst […] |
SQL Server 2017 - Development |
SSIS - Write table to multiple files - Hi there, everyone. I have an SSIS package where I have to write a large table to smaller csv files. I have created a stored procedure as below that is called by an OleDb Source inside a workflow task. This then needs to write each result to a file. I'm very confused as to how […] |
Speeding up Query - Hello, I am new to sql and learning my way around writing views for our company. Any tips and tricks to make this query a little faster or streamlined? SELECT TOP (100) PERCENT ord.orderid, ord.lt_orderid AS LTOrderID, ord.datetimecreated, ord.BookedByDT AS DateTimeBooked, us.firstname + ' ' + us.lastname AS BookedByStaffer, ord.VoidDT AS DateTimeVoided, ord.CancelledByWho, ord.voidreason AS […] |
Need help sorting based on 2 different column DateTime - I've this table and data as following, CreatedDate CANNOT NULL. LatestRepliedDate can NULL CREATE TABLE [dbo].[IncidentMasterSimulation]( [Id] [int] NOT NULL, [IncidentDate] [datetime] NOT NULL, [IncidentDateDisplay] [nvarchar](100) NOT NULL, [HowLong] [nvarchar](100) NOT NULL, [IncidentNo] [nvarchar](100) NOT NULL, [ProjectName] [nvarchar](100) NOT NULL, [Categories] [nvarchar](100) NOT NULL, [PriorityLevel] [nvarchar](100) NOT NULL, [IncidentDescription] [nvarchar](100) NOT NULL, [CreatedBy] [nvarchar](100) NOT […] |
SQL Server 2016 - Administration |
Resource Monitor - Performance Issues - Hi. Last Weekend I have migrate a server with SQL Server 2016 ENT to another machine, and since then, I have facing frequently slow performance issues, the server become unresponsive sometimes. And always I see this message on Windows Event Viewer when peformance degrades. Resource Monitor (0x2290) Worker 0x0000031D8EE88160 appears to be non-yielding on Node […] |
How to get a SQL/CSV list of SCOM alerts and rules - Hello experts, I've been tasked with tuning SCOM alerts for our database environment. Getting the alerts in emails is a little overwhelming and hard to manage. I don't see a way to export a list from the SCOM console, where I have to click through alerts one by one. Does anyone know how I can […] |
SQL Server 2016 - Development and T-SQL |
Dictionary Lookup - Hi I have hundred million ID, NAME pairs stored in SQL Server as a table that is accessed by C# code, which has a responsibility to lookup NAMEs corresponding to million IDs at a time. C# code has these million IDs stored in an array, before invoking SQL module. Columns of the SQL table: […] |
Administration - SQL Server 2014 |
Reclaim disk space after truncate - Hello, We have truncated a huge table (50+ million) rows in sql server which was created for testing purpose. However the disk space is not released back. Any pointers on how to reclaim the disk space after truncating without shrinking database? |
Development - SQL Server 2014 |
how to get quantity from yesterday 6pm till today 6pm - Hi, I am looking to create a case statement that gets different quantities. For example, I would like to see how many orders were created between 6pm yesterday till 6pm today, how much created between 3pm yesterday till 3pm today, and how much was dispatched between 3pm yesterday till 3pm today. I created this case […] |
SQL 2012 - General |
SQL 2012 Service Pack 4 - Cant get TLS 1.2 to work - Hi all, I'm pulling my hair out here trying to get tls 1.2 connections to work from our webserver to the database server. Our 2012 server is patched to service pack 4 so it should be 1.2 enabled. The SQL server native client which is used for the connection is at version 11.0.7462.06 (I don't […] |
Database Integrity Issues - To avoid a lot of contention during peak business hours we separated our integrity checks into weekday and a weekend run. During the week we do a PHYSICAL only and on weekends when activity is lesser, we run a full blown integrity check. While it appears to be inconsistent, sometimes we get errors for a […] |
Rounding problem (?) using DATEDIFF (minutes) - I have a query that is using DATEDIFF to calculate the number of minutes, of course as an integer, but I may need the extra precision of showing this as a decimal (?). Also I'm looking for a way of summing the time based on "EmpID" (using CTE?): SELECT T1.[EmpID], Convert(Datetime,T1.[Time]) AS [Time], MIN(Convert(Datetime,T2.[Time])) AS […] |
SQL Server 2019 - Administration |
SQL Server 2019 Distributed Availability Groups - Hello, I am attempting to create a SQL Server Distributed Availability Group in my Azure EC3 environment. When I attempt to alter my Distributed AG on AG2 using the below command, I get an error as shown below the command. ALTER AVAILABILITY GROUP [WOASQLDISTAG]JOINAVAILABILITY GROUP ON'WAOAG1Hfv96xWgv' WITH(LISTENER_URL = 'TCP://WAOAG121jAavqBc.WAOAG1.com:5022',AVAILABILITY_MODE = ASYNCHRONOUS_COMMIT,FAILOVER_MODE = MANUAL,SEEDING_MODE = MANUAL),'WAOAG2cJ22S7mQO' […] |
SQL Server 2019 - Development |
How to split Xml columns or Json into records - I have to import every days from 1000 to 100000 records. Bulk insert create one record with the complete xml file. its great an very quick. Can we create directly with a bulk insert one record per order, and one column for the xml ot he order. Or how can we do after bulkinsert, to […] |
Reporting Services |
Toggle Item Showing First Row of each group and not collapsing all - If I don't use the Toggle Item and just set detail to Hidden = True, all detail rows are hidden. If I then add a Toggle Item of Textbox that's in the group header, it works, however, it always now shows the first row in each group and the + sign then will show all […] |