SQLServerCentral Article

How do you secure sensitive data in a modern Data Warehouse?

In 2019 Canadian Broadcasting Corporation (CBC) news reported a massive data breach at the Desjardins Group, which is a Canadian financial service cooperative and the largest federation of credit unions in North America. The report indicated, a "malicious" employee copied sensitive personal information collected by Desjardins from their data warehouse. The data breach compromised the […]

External Article

Summit 2022 Call for Speakers Closes Soon

Time is running out to submit your abstract for our hybrid PASS Data Community Summit 2022 conference! If you're an expert in a data-related topic that you think would be perfect for the Summit 2022 program, we want to hear from you. Whether you're planning to attend in-person or online, all session submissions and speakers will be considered for this year's event. Don't miss your chance to speak at the leading conference for data platform pros, submit your proposal before March 31.

Blogs

T-SQL Tuesday #180: Avoid Perfect for Good Enough

By

I'm listening to Effortless by Greg McKeon (link to author's page) through Audible.com. He...

Book Review – Humanizing Data Strategy by Tiankai Feng

By

This book was making its rounds on social media, and the concept seems interesting...

Monday Monitor Tips: Tracking The Cost of Instances

By

One of the things that I’ve been asked in every operations situation is what...

Read the latest Blogs

Forums

Does SSRS Report with Stored Procedure execute SQL string?

By danyeungw

I declare @Where based on the input parameter in the stored procedure. Set @SQL...

SQL Server Constrained Delegation

By cw255

Hi, hoping someone can help. We're in the process of migrating to a new...

Get Sum and Last month sum

By GrassHopper

I want to get the sum and I want to get the sum of...

Visit the forum

Question of the Day

Comparing Images

I am building an ETL process between these tables in SQL Server 2022 set to 160 compatibility level:

CREATE TABLE Image_Staging
( imageid     INT NOT NULL CONSTRAINT Image_StagingPK PRIMARY KEY
, imagestatus TINYINT
, imagebinary IMAGE);
GO

CREATE TABLE Images
( imageid       INT NOT NULL CONSTRAINT ImagesPK PRIMARY KEY
, imagestatus   TINYINT
, imagemodified DATETIME
, imagebinary   IMAGE);
GO
I want to run this query to check if the images already loaded exist. This will help me decide if I need to insert or update an image. What happens with this query?
SELECT i.imageid
FROM
  dbo.Image_Staging AS ist
  INNER JOIN dbo.Images AS i
    ON ist.imagebinary = i.imagebinary;

See possible answers