PC Review


Reply
Thread Tools Rate Thread

How Can I Use DataTable.Select() on a field of type byte[]?

 
 
Leon_Amirreza
Guest
Posts: n/a
 
      1st Mar 2009
Suppose there is a field f1 of type byte[] on table1!
How should I write the select expressions! this doesnt work and causes
error:
table1.Select("f1 = 0xefcda9", "")
also this doesnt work too on c#:
table1.Select("f1 = '0xefcda9'", "")

 
Reply With Quote
 
 
 
 
Miha Markic
Guest
Posts: n/a
 
      2nd Mar 2009
Hi Leon,

You might add a bool column (in memory) to the datatable, set it
accordingly to your condition and then filter (or select) on that column (or
just do a foreach loop and compose your result manually).
I don't think you'll be able to do it with Select method easily.

Miha

"Leon_Amirreza" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Suppose there is a field f1 of type byte[] on table1!
> How should I write the select expressions! this doesnt work and causes
> error:
> table1.Select("f1 = 0xefcda9", "")
> also this doesnt work too on c#:
> table1.Select("f1 = '0xefcda9'", "")
>

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: What type should I set the dataTable column to for byte[] type of Morten Wennevik [C# MVP] Microsoft C# .NET 2 18th Jan 2007 03:07 PM
DataTable - Byte[] Field updating. =?Utf-8?B?TWlsYW5C?= Microsoft ADO .NET 0 16th Mar 2006 11:09 AM
Datatable.Select and datetime type MichalR Microsoft ADO .NET 2 25th Aug 2004 09:02 AM
Search a DataTable on a byte[] field =?Utf-8?B?SkpLYW5l?= Microsoft ADO .NET 5 1st Jun 2004 08:21 PM
DataTable.Select with byte[] SlantyOD Microsoft ADO .NET 0 6th Nov 2003 11:41 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:39 PM.