Laden...
|
|
|
|
|
|
Question of the Day |
Today's question (by Steve Jones - SSC Editor): | |
Two Table Hints | |
What happens when I run this code: SELECT p.ProductName , p.ProductCategory FROM dbo.Product AS p WITH (NOLOCK, TABLOCK); | |
Think you know the answer? Click here, and find out if you are right. |
Yesterday's Question of the Day (by Steve Jones - SSC Editor) |
Post Restore Tasks for the Resource Database I backup the Resource database from my SQL Server 2022 instance. I then install CUs 1, 2, 3, and 4. I have an issue and need to restore my Resource database from backup. Is there anything I need to do after restoring this database? Answer: CU 4 must be reapplied Explanation: Only CU4 needs to be applied. Ref: Backing up and Restoring the Resource Database - https://learn.microsoft.com/en-us/sql/relational-databases/databases/resource-database?view=sql-server-ver16#backing-up-and-restoring-the-resource-database |
Database Pros Who Need Your Help |
Here's a few of the new posts today on the forums. To see more, visit the forums. |
SQL Server 2017 - Administration |
Principal owns a service? - This is one I haven't seen before. I'm trying to drop a database user and got the below message. The login doesn't own any roles or schemas or other objects and everything I google on the error comes up with "principal owns a schema" which is not what this error is. When I try googling […] |
Degraded Performance in 2017 vs 2008 R2 with inserts - We're finally upgrading from SQL Server 2008 R2 Enterprise to SQL Server 2017 Standard and have moved our test database to the new server. Both VMs are on similar hardware with 4 vCPUs. Of course, given the chasm of versions we expected much better performance. Unfortunately, that's not the case. Our inserts on the 2008 […] |
SQL Server 2016 - Administration |
User permissions and showplan - All, I'm trying to find a way to let some of our users see at least some details of a query plan particularly whether an index is being used. I looked at the set statistics statements because the user only needs permissions to run the query but they only specify tables and not indexes? I […] |
SQL Server 2016 - Development and T-SQL |
Slow update on temp table - I have a job running each night starting at 4:30AM and usually finishing at around 6:30AM or shortly thereafter doing some number crunching. Occasionally, this job slows down taking much longer...today it ran until about 8:45AM. This statement, normally would take a second or two...the table is about 250,000 rows with 8 columns...today it took […] |
SQL Server 2012 - T-SQL |
Insert using table unput - I have a table that I need to run off a different server\db and looking for the most efficient way to call from an SP. I need to execute. the field(sqlToExec) as it's loaded with 1000's of Insert statements like below to update this same table on a different server and DB. If something error […] |
SQL Server 2019 - Administration |
Table Partitioning - remove null range - hi guys, I have a partitioned table AM_ITM_INSTNC_MSS and I want to get rid of MYDW_TPData2015 filegroup, how can I achieve that? |
Backup of encrypted databases failing - I've had some backups of my encrypted databases failing with the error "BACKUP 'DBName' detected an error on page (10:12345) in file 'D:\path\DBName_File.ndf' The databases were originally encrypted on a production server and restored to a DEV environment, which may be relevant. All the databases on the DEV server are encrypted, but only two were […] |
SQL Server 2019 - Development |
Create Copy of DB in same server. - Hi I want to create a copy of a DB on the same server. The account that creates the copy DB should NOT be able to read from the original DB but have full rights to the copy DB. Cannot use a snapshot, Changes will be made to the copy and the copy will be […] |
Find the problematic Sql Query Caused Application Crash - Hi, Is there anyway I can find out the sql script ran on a particular date and which might have causes application down? I mean my application was down on 12 April 2024 and based on investigation it was found some sql query running causing the application down. How I can find out what all […] |
Does it make a sense to update statistics right after tables truncated? - Hi all, We have a lengthy process that uses 30 tables, some of them are large. In the beginning we truncate them, then ETL data into them, then massage, perform some calculations, and finally reporting. I am tasked to clean up this process. Right after initial truncation we update statistics on all these tables. Does […] |
SQL Azure - Administration |
zero downtime deployments - Hello, We have azure MI business critical. active read/write, secondary read /only. from what I see most of the HA is handled behind the scenes using Always ON. We have a 30 min downtime every month during product deloyments but one high profile customer wants 0 downtime. How to achieve that with Azure MI Business […] |
Reporting Services |
SSRS Expression IIF Zero then ... Got #Error - Hello, Need some help for SSRS. The column % expression is =iif(sum(Fields!ColumnA.Value) = 0 or sum(Fields!ColumnB.Value) = 0,0,sum(Fields!ColumnB.Value) / sum(Fields!ColumnA.Value)) But I am getting #Error if ColumnA is zerro and no error if ColumnA and B had no value. Please advise. Thank you. |
Analysis Services |
Issues backing up Analysis Services databases - silent failures - I have a PowerShell script that I use to automate the backup of Analysis Services databases - allows for handling new/dropped databases, dynamic filenames, etc. However, on some occasions the backup fails but no output is reported stating why. I get a success message when it works but nothing when it fails. I've tried adding […] |
Strategies and Ideas |
Do I need a recursive query for this? bill of materials (sort of) - I am working on a data warehouse project for a bakery. For the most part, the basic structure is like this: Purchase--(M,1)--Ingredient--(1,M)--Recipe--(M,1)--Product with one exception the "Recipe" part works fine. (IngredientKey, ProductKey, Weight). The part I'm having trouble with is that one ingredient (starter) consists of other ingredients (kinda like a subassembly, if you wanted […] |
Do I need a recursive query for this? bill of materials (sort of) - I am working on a data warehouse project for a bakery. For the most part, the basic structure is like this: Purchase--(M,1)--Ingredient--(1,M)--Recipe--(M,1)--Product with one exception the "Recipe" part works fine. (IngredientKey, ProductKey, Weight). The part I'm having trouble with is that one ingredient (starter) consists of other ingredients (kinda like a subassembly, if you wanted […] |
| |
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved. webmaster@sqlservercentral.com |
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Laden...
Laden...
© 2024