|
|
|
|
|
|
|
|
Question of the Day |
Today's question (by Steve Jones - SSC Editor): | |
High Cardinality | |
When we say a column has high cardinality, what do we mean? | |
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) |
Default Statistics Sampling If I don't specify a percentage of sampling (or fullscan) with CREATE STATISTICS, what is the default percentage of the table sampled? Answer: SQL Server decides based on what determines a high-quality plan Explanation: The actual quote from the docs is: "In most situations, it is not necessary to specify SAMPLE because the query optimizer already uses sampling and determines the statistically significant sample size by default, as required to create high-quality query plans." Ref: CREATE STATISTICS - https://learn.microsoft.com/en-us/sql/t-sql/statements/create-statistics-transact-sql?view=sql-server-ver16 |
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 - Development |
How to establish a relationship in SQL Server - Good morning and Merry Christmas everyone! I'm not sure if anyone has posted something like this before, and if they have, I couldn't find it. And I apologize for the repeat. I'm looking to take the minimum value of a relationship between customers and accounts and apply it to all accounts, thereby establishing a relationship […] |
SQL Server 2016 - Development and T-SQL |
How to validate existing data in a table - Hello Team, I have some application databases where i need to perform data validation. I am not sure what type of data is already stored in the tables. Does there are any set of pre-defined rules / constraints with which i am cross verify data ? Or i have to reply on the application team […] |
Administration - SQL Server 2014 |
FTS Not enabled for DB - but it is working(?) - Hello. I have a couple of DBs that say that Full Text Search is not Enabled on the DB - yet it seems to work? FTS catalogs were created by upgrades to SW that use them to run Contains queries via the portal - this seems to work fine. Maybe the data is stale or […] |
SQL Server 2019 - Development |
Dyanamic SQL to call sproc with input params and an output param - All, I have the following which works perfectly: DECLARE @ProcessName VARCHAR(100) = 'ETL_InitialLoad' ,@TableName SYSNAME = 'dbo.tableA' ,@id NVARCHAR(30) IF NOT EXISTS (SELECT * FROM dbo.ETL_Log WHERE ProcessName = @ProcessName AND TableName = @TableName AND ProcessEndTime IS NULL) BEGIN EXEC [dbo].[ETL_InsertLog] @ProcessName = @ProcessName, @TableName = @TableName, @id = @id OUTPUT; END SELECT @id […] |
Temp Tables Used within Procedure giving error in one 2019 sql server instance - I have Three stored Procedures A,B,C C is a common procedure which derives data into a common table depending on parameters from respective procedures A or B and returns to a or b for further processing on one sql 2019 environment its working normally but on another if Proc A is executed first then later […] |
Managed Instance: Resource alerts with db_mail for usage and notifications? - Hello SQLServerCentral community, I'm looking for guidance on setting up resource alerts for Managed Instance. Specifically, I want to monitor resource usage and receive email notifications when reaching storage or CPU limits. Can someone please provide me with detailed instructions or steps on how to configure this using db_mail? Thank you in advance for your […] |
Reporting Services |
How to use pagination for huge reports - Hi all, I created a SSRS report that supposed to load about 600k records. In order to minimize loading time, I used pagination, by 50 records each page. However, when I refresh it in a Preview mode it throws "out of memory" exception. I expected that if I use pagination it will only load 1st […] |
SSRS Unable to log in to web Portal - Hi guys, I have a new SSRS setup on a new computer, but the default web authentication won't go through no matter what. I've tried adding roles on SSMS, adding Firewall Ports and Authentication and changing my windows info but it all didnt works. Can anyone give me some tips on what to do? Thanks |
Report is Blank in PDF only!? - Hi all, This one is stumping me and I can't tell if this is a bug or a user issue (meaning me). Hoping for some insight. My report consists of a main report with two sub-reports in a table, and my first sub report has its own subreport with a grouping applied. So something like […] |
General |
Task solution help request - Couldy You help me with this task, please? You are working with the library books database. The Books table has the columns id, name, year. The library has new books whose information is stored in another table called "New", however they do not have a year column. Write a query to select the books from both tables, Books and […] |
Analysis Services |
Comparison of rolap and molap in the tubular or multidimensional - I want to write a comparison article on ROLAP and MOLAP, and I have installed SSAS. During the installation process, there was a Tabular section and a Multidimensional section that I needed to choose from. As far as I knew, Tabular is specifically for ROLAP, and Multidimensional is tailored for MOLAP. However, it seems that […] |
Article Discussions by Author |
Always On Failover Availability Group Automation - Hi! I have successfully installed the always-on system from your current repository, and I want to thank you for that. However, while the primary database is inaccessible, I want to be able to write to and update the secondary database. In other words, how can I automatically make the secondary database the primary one in […] |
SQL Server 2022 - Administration |
SQL Server 2022: AlwaysOn AG databases can not sync after applying CU6 or higher - The setup is: OS - Win Server 2022 & MSSQL - SQL Server 2022 AlwaysOn Availability Groups are enabled on two (primary + secondary) replicas and use WSFC. Several availability groups are created and a database in each of them. AGs are configured with Sync Commit and Automatic failover mode, also they use dedicated separate VLAN […] |
SQL Server 2022 - Development |
Freezing of multiple databases using VDI snapshot backup command. - Transact-SQL snapshot backup for SQL Server 2022: Suspend all user databases on the server for a snapshot backup: ALTER SERVER CONFIGURATION SET SUSPEND_FOR_SNAPSHOT_BACKUP = ON; BACKUP SERVER TO DISK = 'd:\temp\db.bkm' WITH METADATA_ONLY, FORMAT; METADATA_ONLY is synonymous with SNAPSHOT. The Virtual Device Interface (VDI) uses SNAPSHOT. VDI Snapshot backup: Backup statement: BACKUP DATABASE {database_name} TO […] |
Return - Self taught novice learning SQL and would welcome some help with the following code problem In my data set I have one record per customer but would like my select query to return 12 rows for each customer record in the data set. e.g. If I have 2 customers I would end up with 24 […] |
| |
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved. webmaster@sqlservercentral.com |