"Duy Nguyen" <tieuta@hotmail.com> wrote in message
news:eeDMuYo8DHA.3404@TK2MSFTNGP09.phx.gbl...
> To John,
> I found an answer to this:
> Public Function ByteArrayToString(ByVal bytArray() As Byte) As String
> Dim UTF8 As New UTF8Encoding()
> Return UTF8.GetString(bytArray)
> End Function
>
> from
http://www.dotnet247.com/247reference/msgs/26/133524.aspx >
> Thanks,
>
> Duy Nguyen
>
> "John Kane" <jt-kane@comcast.net> wrote in message
> news:#82XVUn8DHA.3200@TK2MSFTNGP09.phx.gbl...
> > Duy,
> > You're at the right place & talking to the right guy! ;-)
> > You don't have to "convert the image file", the T-SQL FTS predicates of
> > CONTAINS or FREETEXT does it for you.
> > For example, if I store a MS Word document (or HTML file) as a binary
file
> > into a column defined as IMAGE and this document file contains the
phrase
> > "SQL Server" and this column is successfully FT Indexed and the FT
Catalog
> > is successfully populated, I can issue the following T-SQL FTS query to
> find
> > this document without converting the binary text, for example:
> >
> > SELECT PKey, Image_column from Table_with_Document where
> > CONTAINS(Image_column,'"SQL Server"')
> > SELECT PKey, Image_column from Table_with_Document where
FREETEXT(*,'"SQL
> > Server"')
> >
> > Once you have the unique Primary Key (PKey), you can use the ADO.NET and
> > ASP.NET code examples in the following KB article to retrieve the file
and
> > display it to your searcher as a MS Word document (or HTML file):
> > 326502 (Q326502) HOW TO: Read and Write BLOB Data by Using ADO.NET
Through
> > ASP.NET
> >
http://support.microsoft.com/?id=326502 > >
> > You might also find the following KB articles useful as well:
> > 309158 (Q309158) HOW TO: Read and Write BLOB Data by Using ADO.NET with
C#
> >
http://support.microsoft.com/default.aspx?scid=kb;EN-US;309158 > > 308042 (Q308042) HOW TO: Read and Write BLOB Data by Using ADO.NET with
> > VB.NET
> >
http://support.microsoft.com/default.aspx?scid=kb;EN-US;308042 > >
> > Hope this is helpful!
> > Regards,
> > John
> >
> >
> >
> > "Duy Nguyen" <tieuta@hotmail.com> wrote in message
> > news:ethEJwm8DHA.2540@TK2MSFTNGP11.phx.gbl...
> > > I don't know if I should post here or aspnet community. If you know
an
> > > answer to this, I'll be much appreciated.
> > >
> > > (SQl Server) I created a table for full-text search. It has an image
> > field
> > > to store my html files and a field for extensions.
> > > However, when I retrieve data from SQL Server, I don't know how to
> convert
> > > the image file from the table to string so that the string becomes
part
> of
> > > html codes. I'm using ASP .net (VB) to retrieve the files.
> > >
> > > i.e.,
> > > Table: Papers (for full text search)
> > > Fields: imgFile IMAGE,
> > > chrExtension VARCHAR(4)
> > >
> > >
> > > ASP .NET
> > > How can I retrieve files in the table Papers, turn them into strings,
> and
> > > concatenate the strings with some other strings in my Asp .net.
> > >
> > > Thanks in advance!
> > >
> > > DN
> > >
> > >
> >
> >
>
>