Solved

SSIS Compare TEXT Fields

Posted on 2013-12-19
3
432 Views
Last Modified: 2016-02-10
I need to compare two TEXT Fields from two tables to identify the changed records using SSIS 2005. How do I compare TEXT fields? can you please suggest any approach?
0
Comment
Question by:MRPT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 66

Expert Comment

by:Jim Horn
ID: 39729631
We can suggest any approach as long as you can clearly define what you wish to do.

Spell out for us the table design of these two tables and which columns you wish to comapre.
Also spell out for us the movement of data so we know what is 'old' and 'new'.
0
 

Author Comment

by:MRPT
ID: 39729908
I have a Stage table which has new and updated  data
STAGE TABLE
CREATE TABLE [dbo].[StageData](
      ID int NOT NULL,
      Date datetime NULL,
      Name VARCHAR(50) NULL,
      NOTES TEXT NULL
)

This stage table columns needs to be compared to the another table (dbo.FinalTable- which has old data) to determine if any column value has changed, If changed, then update the value in the Final Table with the new value from stage table

CREATE TABLE [dbo].[FinalTable](
      ID int NOT NULL,
      Date datetime NULL,
      Name VARCHAR(50) NULL,
      NOTES TEXT NULL
)

I use CozyRoc to determine new and updated records. It works fine for all columns expect TEXT field Column

How can I compare TEXT Fields column to determine if the value as changed?
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 500 total points
ID: 39733189
How can I compare TEXT Fields column to determine if the value as changed?
Answer: Don't use text data types use varchar(MAX) instead.

Text data types have been deprecated for over 8 years and should not be used any more.
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question