JPEG Markers Corrupted

Compares and synchronizes SQL database content.

Moderators: JonathanWatts, Chris Auckland, David Atkinson, Michelle Taylor, chengvoon.tong

JPEG Markers Corrupted

Postby richard_collette@hsb.com » Wed Mar 26, 2014 5:35 pm

I have database A with an nvarchar(max) column containing images. The data was copied to database B with Sql Data Compare. Both columns are SQL_Latin1_General_CP1_CI_AS collation. When I save the data to a file from each database and compared using beyond compare, the image in database b had an invalid jpeg marker but otherwise beyond compare was able to display the image.

Looking at the data in SSMS, the first character of the good image starts with a box while the bad image first character starts with a diamond.

When I compare the two tables with SQL Data Compare, at first no differences were seen. When I set the comparison to use binary collation, then differences were seen, but when I updated database b, the first character remained a diamond instead of a box. When Sql Data Compare displays the side by side data, both columns show a diamond as the first character rather than showing a box for the column from database A.

For some reason Sql Data Compare is not correctly reading the data from the database during its comparison.

I used SSMS to update the data in database b and the images are all fine.
richard_collette@hsb.com
 
Posts: 5
Joined: Fri Jun 08, 2012 2:29 pm

Postby Manfred.Castro » Thu Mar 27, 2014 12:52 am

Hi Richard,

Are you using the tool to sync or generating a script and then syncing via SSMS?

It sounds like it could be an encoding issue.

You may want to try changing the encoding of the deployment scripts in your Application options.

Located in Tools -> Application options

I am not really sure which encoding option you will have to select so you may need to try each one to see if you get a better result.

Manfred
Manfred Castro
Product Support
Red Gate Software
Manfred.Castro
 
Posts: 209
Joined: Mon Apr 23, 2012 2:49 pm


Return to SQL Data Compare 10

Who is online

Users browsing this forum: No registered users and 0 guests