home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.databases.ms-sqlserver      Notorious Rube Goldberg contraption      19,505 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 17,811 of 19,505   
   Erland Sommarskog to Iain Sharp   
   Re: Strip the first byte from an image c   
   08 Jun 10 22:32:43   
   
   XPost: microsoft.public.sqlserver.programming   
   From: esquel@sommarskog.se   
      
   Iain Sharp (iains@pciltd.co.uk) writes:   
   > Okay, dumping the data to a file from the application and reloading it   
   > without the # character allows Crystal to display the image correctly.   
   > So, unless the application is doing something else to the data (and   
   > the manual says,   
   >   
   >      /image?reads the raw data from FileName, assuming that this   
   >      data is an image. An initial hash character (#) is added to   
   >      the data before copying the data to Target. (The hash   
   >      character is an indicator to show that image data follows.) No   
   >      further conversion is performed on the data.   
   >      /raw?behaves similarly to the /image switch, except that the   
   >      data in FileName is assumed not to be an image; an initial   
   >      hash character (#) is not added. No further conversion is   
   >      performed on the data.   
   >   
   > Data stored /image is what I have, data stored /raw is working   
   > correctly. So I presume it's the substring() or right() that is   
   > corrupting it....   
      
   I would suggest that you look at the dump from the application in a binary   
   editor and compare with what you have in the database, not the least   
   after the stripping. One possility is that this small-endian thing causes   
   a byte swap.   
      
      
   --   
   Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se   
      
   Links for SQL Server Books Online:   
   SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx   
   SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx   
   SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca