|
|
|
start date: Wed, 11 Jul 2007 14:04:51 -0600,
posted on: microsoft.public.dotnet.framework.adonet
back
| Thread Index |
|
1
Ronald S. Cook
|
|
2
Cor Ligthert [MVP]
|
How sort DataView so blanks are at bottom, not top?
I have a DataTable with column "Sequence". Values are like:
Sequence
--------
5
1
3
(blank/null)
7
6
(blank/null)
4
When I create a DataView and do a sort, I get
Sequence
--------
(blank/null)
(blank/null)
1
2
3
4
5
6
7
But I need the blank/nulls to be at the end like
Sequence
--------
1
2
3
4
5
6
7
(blank/null)
(blank/null)
How can I do this, please?
Thanks,
Ron
Date:Wed, 11 Jul 2007 14:04:51 -0600
Author:
|
Re: How sort DataView so blanks are at bottom, not top?
Ronald,
The only thing I can think about what uses a short answer is:
Add an extra column with the contents of your column
Replace in that column all spaces by ZZZZZZ (or any other high value)
Use that as the sort item.
Cor
"Ronald S. Cook" schreef in bericht
news:%23wecFb$wHHA.4588@TK2MSFTNGP03.phx.gbl...
>I have a DataTable with column "Sequence". Values are like:
>
> Sequence
> --------
> 5
> 1
> 3
> (blank/null)
> 7
> 6
> (blank/null)
> 4
>
>
> When I create a DataView and do a sort, I get
>
> Sequence
> --------
> (blank/null)
> (blank/null)
> 1
> 2
> 3
> 4
> 5
> 6
> 7
>
> But I need the blank/nulls to be at the end like
>
> Sequence
> --------
> 1
> 2
> 3
> 4
> 5
> 6
> 7
> (blank/null)
> (blank/null)
>
>
> How can I do this, please?
>
> Thanks,
> Ron
>
Date:Sat, 14 Jul 2007 06:31:41 +0200
Author:
|
|
|