List Info

Thread: Which DbType to use for large binary fields (ntext)?




Which DbType to use for large binary fields (ntext)?
user name
2006-09-21 07:22:30
> Thank you very much for your reply. Does this mean that
if I
> want to store files in the database (Excel & Word -
this is a
> very real possibility for my project), I'll have to
convert
> the binary content into a string to save it into the
database
> and then back from string to bytes when reading it? I
assume
> this is the only solution, since DbType.String seems to
be
> the only one without a (very low) size limit. (BTW, I
use SQL
> Server 2000 for the
> project.)

        And btw, excel/word docs are binary data, you should
store them as byte[] in memory and set the Value property of
the
parameter to that byte[], in the DB you should store it in
an Image field, not an ntext field.

                FB

===================================
This list is hosted by DevelopMentorŪ  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )