|
|
|
|
|
|
|
Question of the Day |
Today's question (by Steve Jones - SSC Editor): | |
The Hash Join III | |
In a hash join, if all the build input does not fit in memory, what type of hash join is this? | |
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) |
Getting ANY of the data I have this data in two tables: -- Beer table BeerIDBeerNamebrewer 5Becks Interbrew 6Fat Tire New Belgium 7Mac n Jacks Mac & Jack's Brewery 8Alaskan AmberAlaskan Brewing 9Kirin Kirin Brewing -- Beercount table BeerName BottleCount Becks 5 Fat Tire 1 Mac n Jacks 2 Alaskan Amber 4 NULL 7 Corona 2 Tsing Tao 4 Kirin 12 What is returned from this query? SELECT * FROM dbo.BeerCount AS bc WHERE bc.BeerName=ANY (SELECT b2.BeerName FROM dbo.Beer AS b2);
Answer: 5 rows and 2 columns Explanation: This returns 5 rows and 2 columns. The two columns are from the beer count table, and the five rows returned match the 5 names from the beer table. Ref: ANY - https://learn.microsoft.com/en-us/sql/t-sql/language-elements/some-any-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 2016 - Administration |
NC index creation duration question - Hey All, My setup is as follows: Table with Clustered Index on ID col. Size 13 GB. 200+ fields, many LOB cols. Single non-clustered index with key CaseNumber and 2 include columns. Size 200 MB. Server performance was good, normal, i.e. hardware doesn't explain the issue. Scenario: I attempted to add a new Non-clustered index […] |
SQL Server 2016 - Development and T-SQL |
Group Delete - I have 2 tables which I need to cleanup old costkeys, based upon a driver table. The driver table is [CostKeyDeletes] and used as input to the cstdetails for cleanup. The costkeys very in record counts so I need a batchsize limit. I would like see logging of the process showing which CostKey it working […] |
identify consecutive records greater than 1 - Hello I need help identifying all records that have consecutive hours (time in order) of greater than 1 for the value field. The output I am looking for would have Number,Start Time,End Time, Average of val over that time range that is identified. create table LunchTable ( Number integer, Value decimal(15,2), StartTime datetime ); insert […] |
SQL Server 2019 - Administration |
Transparent Data Encryption (TDE) on AlwaysON Availability Group - I’ve been tasked with securing SQL Server data and log files (MDF and LDF) using Transparent Data Encryption (TDE) across all SQL Servers in our environment, which consists of over 85 instances. This is a significant undertaking, and I’m concerned about the potential impact of deploying TDE universally across such a large number of servers, […] |
SQL Server migration using replication - I've set up replication in my SQL 2019 environment in attempt to migrate SQL databases individually from one datacenter to another. in my testing of one database several issues were found and any advice would be appreciated. 1. There several missing indexes 2. very large tables cannot be filtered on for transaction replication(post snapshot migration) […] |
SQL Server 2019 - Development |
funny character shows in one hdg name in ssis flat file connector - hi, i spent some time today in an existing pkg replumbing 5 flat file connectors to new tsv files. eventually that will be automated. 2 of my connectors show the bizarre character shown below prior to my first hdg name. on one i'm not sure what i did but i chose the file in the […] |
Reporting Services |
Migrating from SSRS 2008 (SP Integrated) to 2022 (Native) - Has anyone done a migration from sharepoint integrated ssrs to native? I'm not finding any specific documentation for this use case. We were able to get the reports migrated via the RS utility and ssrs_migration script provided by microsoft but the subscriptions and report history didnt come across. From the microsoft documentation it seems we're […] |
change server connection - I have a one database and one table in that database. This is on 100 servers. Same db and table name 1.Can I build a report which will change server connection based on the server selected in a drop down list of 100 servers. Can the select data from multiple servers based on a check […] |
Strategies and Ideas |
Automating DAX Studio... - Still trying to figure out options for automating the export the result of a PowerQuery to SQL Server. Turns out that if I have DAX Studio installed, I can do this: Open my PBIX file that contains the PowerQuery I want to export the results from. Open DAX Studio from inside PowerBI. Go to the […] |
Integration Services |
Call dynamic sql storedprocedure from SSIS execute sql task - hi, I have a table called Rules Create table Rules ( Id int , Rules Statement Nvarcahr(max) ) values Id RulesStatement 1 Sp_execute_rules @job_id , @run_id,@createid So , i will be passing the parameters from my ssis package and calling the storedprocedure. this is how i am calling in execute sql task […] |
Working with Oracle |
CPU Performance Advice in SQL Server 2005 - I am having problems with CPU performance on SQL Server 2005. CPU spikes frequently to 90-100% for no apparent reason. I have checked the running jobs and queries but found nothing unusual. The server has about 30 concurrent connections and the database is about 5GB. - Check long queries and optimize them. - Use SQL […] |
CPU Performance Advice in SQL Server 2005 - I am having problems with CPU performance on SQL Server 2005. CPU spikes frequently to 90-100% for no apparent reason. I have checked the running jobs and queries but found nothing unusual. The server has about 30 concurrent connections and the database is about 5GB. - Check long queries and optimize them. - Use SQL […] |
SQL Server 2022 - Administration |
Duplicate Documents - Hi Experts, I am trying to find duplicate documents stored in our Filestream database. I have come across multiple documents with same size, created timestamp within minutes\secconds difference, same filename. Is there a better way to identify the duplicate files? Regards |
Migrating database with many orphan users. - I am currently upgrading a very old database running SQL Server 2008 to SQL Server 2022 using export & import method to a new server. I have migrated the necessary objects e.g. logins, linked servers & configuration to the new server successfully. For logins, I use revlogin procedure to script out all the logins from […] |
SQL Server 2022 - Development |
Cannot install development version. - A while into install I get a Microsoft OLE DB Driver for SQL Server. The feature you are trying to use is on a network resource that is unavailable. It is looking for msoledbsql.msi. I have one locally but than I get a message: The file 'D:\msoledbsql.msi' is not a valid installation package for the […] |
| |
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved. webmaster@sqlservercentral.com |