🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.databases.ms-access
3 messages
3 total messages Started by Bruce Collins Wed, 05 Nov 1997 00:00
alphanumerics
#433
Author: Bruce Collins
Date: Wed, 05 Nov 1997 00:00
12 lines
1723 bytes
I have a list of numbers as well as the occasional text in a text field that
I need to sort.  ie entries could be 135, 12, 406, bru, 1128.

If I sort them normally they come out as 1128,12,135,406,bru.

If I use a Val function before sorting this turns the bru into a 0 value.

The only solution I can see is putting zeros in front of each number but
with 1400 entries I don't want to do this manually!!

Is there a way that someone else has found to get around this problem?
Re: alphanumerics
#437
Author: Uli Reinbeck
Date: Wed, 05 Nov 1997 00:00
29 lines
2231 bytes
Hello Bruce,

could you give your question a bit more precisely?
What sorting order do you want to achieve, why do you want to use the
val-function??

Uli

--
------------------------------------------------------------
 Ulrich Reinbeck, Bismarckstr. 52, 70197 Stuttgart (Germany)
 reinbeck@tick.informatik.uni-stuttgart.de
------------------------------------------------------------


Bruce Collins wrote:

> I have a list of numbers as well as the occasional text in a text field that
> I need to sort.  ie entries could be 135, 12, 406, bru, 1128.
>
> If I sort them normally they come out as 1128,12,135,406,bru.
>
> If I use a Val function before sorting this turns the bru into a 0 value.
>
> The only solution I can see is putting zeros in front of each number but
> with 1400 entries I don't want to do this manually!!
>
> Is there a way that someone else has found to get around this problem?
Re: alphanumerics
#438
Author: Mike S.
Date: Thu, 06 Nov 1997 00:00
26 lines
2207 bytes
Bruce,
Here is a way around it.  Try this query (assuming the field SomeID holds
the 135, 12, 406...):

SELECT MyTable.SomeID FROM MyTable ORDER BY Right("00000" & [SomeID], 5);

Use as many zeros as needed and cut it to a size you know it is safe and not
going to trim your id.

Mike S.
Optimal Systems Corp.  www.oscorp.com
----------------------------------------------------------
Bruce Collins wrote in message <63pctq$qf9$1@fep4.clear.net.nz>...
>I have a list of numbers as well as the occasional text in a text field
that
>I need to sort.  ie entries could be 135, 12, 406, bru, 1128.
>
>If I sort them normally they come out as 1128,12,135,406,bru.
>
>If I use a Val function before sorting this turns the bru into a 0 value.
>
>The only solution I can see is putting zeros in front of each number but
>with 1400 entries I don't want to do this manually!!
>
>Is there a way that someone else has found to get around this problem?
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads