Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Insert a Word file in SQL Server
Message
 
 
À
27/08/2004 20:47:10
Peter Wagner
Point Informática Ltda.
Limeira, Brésil
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Divers
Thread ID:
00936777
Message ID:
00937399
Vues:
23
Peter,

A word document is a binary file. The image data type is designed to store binary data. The SQL Server doesn't make any attempts to interpret such data and sends them back and forth unchanged.
The text and ntext data types are designed to store text data. Those data types could be affected by page translation or some other conversions SQL Server, ODBC driver or OLE DB provider decide to perform.
The bottom line, I would store a binary data in the image column to avoid unplasant feature surprises.

>Thanks for the link, but I have a question about it.
>In the link Vlad says...:
>
>Text field on SQL Server is not good to store binary data because it is not
>reliable and often SQL Server corrupts binary data in text field
>
>And
>
>When binary data passed to SQL Server, they're encoded to match the
>format required for SELECT statement in T-SQL.
>
>
>In my test I'm doing this:
<snip>>
>I made some test and the code works fine with SQL Server, and I'm able to get the value from a Text field in a SQL Table, and transform it into a Word document again without problems.
>My question is: Did You had any problem storing data in Text fields ?
>I'm afraid that it works fine now but later it brings me in trouble because I missed something.
>I wasnt able to see any problem like the one described by Vlad.
>
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform